This is to inform to you that seems to be a bug around:
- ColumnCOUNT
I've make a simple test as follow (based on C:\hmg.3.4.0\SAMPLES\Controls\Grid\GRID_04\demo.prg):
This return of msgdebug(GetProperty("Form_1","Grid_1","ColumnCOUNT")) is NILCode: Select all
/* * HMG Virtual Grid Demo * (c) 2003 Roberto lopez */ #include "hmg.ch" Function Main DEFINE WINDOW Form_1 ; AT 0,0 ; WIDTH 450 ; HEIGHT 400 ; TITLE 'Hello World!' ; MAIN DEFINE MAIN MENU DEFINE POPUP 'File' MENUITEM 'Change ItemCount' ACTION Form_1.Grid_1.ItemCount := Val(InputBox('New Value','Change ItemCount')) END POPUP END MENU @ 10,10 GRID Grid_1 ; WIDTH 400 ; HEIGHT 330 ; HEADERS {'Column 1','Column 2','Column 3'} ; WIDTHS {140,140,140}; VIRTUAL ; ITEMCOUNT 100000000 ; ON QUERYDATA QueryTest() MULTISELECT END WINDOW CENTER WINDOW Form_1 msgdebug(GetProperty("Form_1","Grid_1","ColumnCOUNT")) ACTIVATE WINDOW Form_1 Return Procedure QueryTest() This.QueryData := 'ர' + Str ( This.QueryRowIndex ) + ',' + Str ( This.QueryColIndex ) Return
But if in place you test with msgdebug(Len(_HMG_SYSDATA [ 7 ] [GetControlIndex("Grid_1","Form_1")])) then returns 3 (ok, regarding number of headers/columns).
- ColumnWIDTH not working too... but with LISTVIEW_GETCOLUMNWIDTH, yes it's working...
- ColumnHEADER not working too... and trhru _HMG_SYSDATA [ 7 ] [GetControlIndex("Grid_1","Form_1")] [nColIndex], yes it's working...
Should it be no reason of this wrong behaviour, not for being MultiGrid or Virtual Grid, doesn't it ?
Please confirm.