How can i adjust the column length of my grid?
http://www.vbforums.com/attachment.p...postid=1780356
Printable View
How can i adjust the column length of my grid?
http://www.vbforums.com/attachment.p...postid=1780356
If you build the headings with .FORMATSTRING, then the "number of characters" - including trailing spaces makes up the width.
Otherwise, the .COLWIDTH property allows you to be specific.
How did they get to be the size they are now? Is this a regular flex grid or is it some kind of bound data grid (which I have no personnal experience with).
yes this is a regular flex grid
Code:With YourFlexGrid
.Colwidth(0) = .Width * 0.1
.Colwidth(1) = .Width - .ColWidth(0)
End With
why is it the a portion only of the text message appeared..... ? is there anyway that the grid column can adjust to the text length?
you can adjust the first col based on the width of the widest column, but it the concept first originated from spreadsheets, in which long text wouldn't overwrite cells unless the cell to the right was not occupied.
look closely to my grid and the grid size.... i want to capture all the text up to the last column... i used word wrap nothing happened
Here we create multiple lines in a FLEXGRID by inserting "vbCR" characters:
VB Code:
flxPosting.TextMatrix(rsRows, 3) = flxPosting.TextMatrix(rsRows, 3) & vbCr & rs2!ATTTYPE & " " _ & setTime(rs2!ATTTIME) & " " & setTime(rs2!ATTRTNTIME)
Also causing us to adjust row height:
VB Code:
If flxPosting.RowHeightMin = 0 Then flxPosting.RowHeightMin = flxPosting.RowHeight(rsRows) End If flxPosting.RowHeight(rsRows) = flxPosting.RowHeight(rsRows) _ + flxPosting.RowHeightMin
We store the original ROWHEIGHT in ROWHEIGHTMIN - just so we can use it to adjust row heights when needed