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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VB-FlexGrid 2

Status
Not open for further replies.

aos

MIS
Feb 28, 2002
20
0
0
US
Hi!I am wondering how to automatically have the whole text in each cell visible without having to stretch the cell to read the text.
thanks!
 
The short answer is, you can't.
What you can do is use the click event for the grid to open a form containing only a label to display the full contents of the cell you clicked and a return button (or the close form button)

Or you can set the wordwrap property "true." It will allow the cell to grow in height to accomodate all of the text (width remains fixed.) This tends to make your grids really ugly though.
 
You can also set the width at run time with something like this:

flexgrid.ColWidth(1) = Me.TextWidth(String$(Len(MyString), "X"))

That can get a little hairy, though, we usually just let the users stretch the darn thing :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top