Jamie,
Try this:
amembers(acursors, thisform.dataenvironment, 2)
for i = 1 to ALEN(acursors,1)
oDataEnv = EVAL("thisform.dataenvironment." + acursors[i])
if oDataEnv.baseclass = "Cursor"
oDataEnv.cursorsource = cpathvar + oDataEnv.cursorsource
endif
endfor
HTH
Barbara
>Barbara,
>Thanks, this works fine but....To take it a little further, is there a way to find the number of cursors contained in a form's dataenvironment by way of an array or some type of function? This way I could set up a loop through the array and change the path without hardcoding all the seperate statements.
>Thanks again,
>Jamie
>
>>You can put code into the DataEnvironment BeforeOpenTables event which re-sets the path. There have been several recent threads about this, and since you're PUTM, I suggest a search for ALL the info instead of a quick re-hash. You can add this code to your base form, and not have to update every form.
>>
>>HTH
>>Barbara