FIX: Grid Custom Control RemoveItem Does Not Update RowHeight (85436)
The information in this article applies to:
- Microsoft Visual Basic Standard Edition for Windows 2.0
- Microsoft Professional Toolkit for Microsoft Visual Basic programming system for Windows
This article was previously published under Q85436 SYMPTOMS
If you change the RowHeight property of a Grid control, and then delete
a row by using the RemoveItem method, the grid adjusts the height of the
rows below the deleted row to their default size. However, it does not
update the RowHeight property for those rows. If you reset the RowHeight
property to its current value, the Grid does not re-draw the rows to
the size given by RowHeight.
WORKAROUND
To work around the problem, set RowHeight to a different value and
then change it back to the original value.
For example, replace the code shown in the Command1 Click event in step
6 of the More Information section below with this code:
Sub Command1_Click ()
For count% = 0 To Grid1.Rows - 1
Grid1.RowHeight(count%) = 399
Next count%
For count% = 0 To Grid1.Rows - 1
Grid1.RowHeight(count%) = 400
Next count%
End Sub
STATUS
Microsoft has confirmed this to be a bug in the Grid custom control
supplied with the products listed above. This problem was corrected
in the Grid custom control shipped with Microsoft Visual Basic version
3.0 for Windows.
Modification Type: | Major | Last Reviewed: | 10/29/2003 |
---|
Keywords: | kbbug kbfix KB85436 |
---|
|