|
-
Aug 24th, 2001, 05:55 AM
#1
Can I do This?
using a loop I search through a dataset, if a match is not found, i then open another form that reads the original database recordset, I would like at this point to add a new record, close the opened form, make the original form visible and continue the code from where I left off in the original loop.
ie.
do until
seek
found a match do this
blah blah...
NOT found a match
open other form
view records
add new record
save
close form
continue with code
loop
The problem is that when I do this, a) the original code within the loop wants to continue, b) probably because of this I can't update the datagrid on the newly opened form......any hints?
-
Aug 24th, 2001, 06:02 AM
#2
You could try showing the form Modally (see the help on Show), that way your code won't continue until the form is closed again. Obviously you will have to put all of the code to work with the form into the form itself.
-
Aug 24th, 2001, 06:04 AM
#3
Trye opening the new form with this code:
Code:
frmNew.show vbmodal, me
this shows the form in modal mode, which breaks the execution flow of the calling form. Perhaps that will fix your problem.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|