Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Setting ColumnWidths In Code
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01034883
Message ID:
01035165
Views:
22
Ok, I'm not sure exactly how to go about this.
? LEN("This is a long caption") && Returns 22
? TXTWIDTH("This is a long caption","Arial",9)  && Returns 34.400
The width of the container below the label is 119, yet visually the are
the same width.

So I'm not sure how to determine the correct size of a list column based on
another object's width.

Here's a link to an image of what I want to do.

The list columns should be the same width as the header containers above them.

Any ideas?

Thanks



>Kevin,
>
>Look at the fontmetric() and txtwidth() functions.
>
>>I need to set the ColumnWidth of a listbox in accordance with the
>>widths of other controls.
>>
>>For example, if I have a container with a width of 35, then the column might
>>be 45 using font Arial.
>>
>>The question is, how to I calculate the ColumnWidths regardless of the font?
Everything makes sense in someone's mind
public class SystemCrasher :ICrashable
In addition, an integer field is not for irrational people
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform