Home » Community » Newbie corner » GridCtrl help needed
Re: GridCtrl help needed [message #32651 is a reply to message #32650] |
Tue, 31 May 2011 14:10   |
|
Hi!
SetCtrlValue doesn't work, because controls are not created yet. They will be created during window opening. To make it work in your case call SyncCtrls before setting control values:
grid.Add();
grid.SyncCtrls();
grid.GoBegin();
for(int col = 0; col < 10; col++)
grid.SetCtrlValue(col, "a string");
But the simplest and the best way is to replace SetCtrlValue with Set. In proper time controls will be automatically populated with underlying grid values;
grid.Add();
grid.GoBegin();
for(int col = 0; col < 10; col++)
grid.Set(col, "a string");
|
|
|
Goto Forum:
Current Time: Fri Aug 22 10:50:03 CEST 2025
Total time taken to generate the page: 0.06310 seconds
|