Hi all,
I am attempting to run the following code upon a form in order to remove a table from the forms data maodel, sort upon user specified criteria on the table and then add the table back into the data model.
method pushButton(var eventInfo Event)
var
strName String
endvar
strName = ("PartReport.db"
if dmHasTable(strName) then
dmRemoveTable(strName)
dlgsort(strName)
dmAddTable(strname)
endif
endMethod
The problem with this code is that it tries to run the dlgsort before the table has been removed, therefore telling me that the table is in use. Is there anyway I can adapt this code, adding some kind of segmentation, executing each part of code before the next is run.
Any help is much appreciated!
Thanks,
Woody.
I am attempting to run the following code upon a form in order to remove a table from the forms data maodel, sort upon user specified criteria on the table and then add the table back into the data model.
method pushButton(var eventInfo Event)
var
strName String
endvar
strName = ("PartReport.db"
if dmHasTable(strName) then
dmRemoveTable(strName)
dlgsort(strName)
dmAddTable(strname)
endif
endMethod
The problem with this code is that it tries to run the dlgsort before the table has been removed, therefore telling me that the table is in use. Is there anyway I can adapt this code, adding some kind of segmentation, executing each part of code before the next is run.
Any help is much appreciated!
Thanks,
Woody.