>I think you want to do something like this:
>
>* grdX.column(variable).controlsource = x
>For I=1 to Y
> Variable = ALLT(STR(I)) + '.'
> grdX.column&Variable.controlsource = x
>EndFor
That's like my second idea, but for looping, I think my first idea is cleaner:
For n = 1 to grid.columncount
grid.columns(n).pem = etc...
Endfor
Or you could use the 'For Each oColumn' method if you like...
Of course these loops aren't good for assigning controlsources, since they're probably going to be unique, unless you add something like AFIELDS or FIELD to grab the field name for each column...
The Anonymous Bureaucrat,
and frankly, quite content not to be
a member of either major US political party.