Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Crazy mixed up Grid
Message
From
29/05/2002 16:38:06
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Crazy mixed up Grid
Miscellaneous
Thread ID:
00662722
Message ID:
00662722
Views:
50
I am using a grid class as paraphrased below:
with logrid
  .ColumnCount = 3
  .RecordssourceType = 1
  .Recordsource = 'SomeCursor'
  .columns(i).ControlSource = 'SomeCursor.Field3'
  .columns(2).ControlSource = 'SomeCursor.Field1'
  .columns(3).ControlSource = 'SomeCursor.Field2'
endwith

...

Function Form::Load
  this.ViewRequery()


function ViewRequery
thisform.Grid1.recordsource = ''
lcSql = 'select field1,field2,field3 from sometable into cursor SomeCursor'
thisform.Grid1.recordsource = 'SomeCursor'
After the first requery of the cursor all is well, however on subsequent requeries the columns revert to cursor field order. If I re-assign column controlsources after the requery all is well again. What am I missing?

Glenn
Next
Reply
Map
View

Click here to load this message in the networking platform