Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations sizbut on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to change header width in a browse-change grid

Status
Not open for further replies.

mibosoft

Programmer
Jul 23, 2002
106
SE
Hi,
When I change the value of grid.view in my grid from 0 to 1 (from browse-browse to browse-change) during run-time, the header column width in the "change" partition is to small to show the whole caption text. How do I change this width? The browse partition looks fine (header width is ok).

Thanks,
Micael
 
I've never changed this property before, and I have a feeling that just about no one else has either. The Change interface isn't very friendly. IAC, I see the problem you're talking about, and I can submit this as a bug for you, but I wouldn't count on it getting fixed until VFP 9 comes out.

Sorry, but I don't have a workaround for you.



-BP
 
OK. Autosize of this column is what I would have expected. Please report this as a bug if you can.

Thanks for your answer,
Micael
 
Yes! Finally I know how to control this bastard!
The width of the caption column in a 'change' partition depends on the name of the header. This means that renaming "grid1.column1.header1" to "grid1.column1.header111111111111" gives me a wider column :)

 
Even changing the header name doesn't fix it for me. Neither does changing the header caption. I've reported this to Microsoft as a bug, but as I said, they're working on VFP 9 now, so I wouldn't expect a fix in VFP 8.


-BP (Barbara Peisch)
 
Normanbates,
You can solve that problem by adding some space characters after caption property.
header1.caption="Name"
header1.caption="Name" +space(5)


Viet
 
Viettla,
It is not the caption name that controls the width. It is the name of the header (strange).

BPeish,
I create my form and grid programatically. The header is added with "addobject(header11111 ...)". Maybe that makes the difference. Good that you have reported it as a bug.

Thanks,
Micael
 
Micael,

Adding the header programmatically probably is what makes the difference. I only tried it at design time.


-BP (Barbara Peisch)
 
It turns out, this whole problem only exists at design time. If I run the form that looks awful in the designer, it looks fine when it runs. I've clarified this bug with Microsoft.


-BP (Barbara Peisch)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top