Steve,

I'm running a file as shown which edits using the first form.

One button on the form saves the row, sets the flag variable to the name of the 
second form, and does a close window
Two other buttons do the closewindow, setting the flag to "QUIT'. One of the 
buttons does a saverow before close window while the other does not.

This example give the usere 3 options:
Save and go to the second form.
Save and quit
Quit without saving.

Look at my code. When the first form exists, the flag determines what happens 
next, quit or call the code that runs the second form.

So, the idea is that you do not run forms from within forms.
You exit a form and determine what to do next.
I run each form from their own little code file so control is simple.

Dennis







-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Steve Breen
Sent: Monday, November 30, 2009 1:31 PM
To: RBASE-L Mailing List
Subject: [RBASE-L] - Re: saving data in form to table

Dennis and Karen,
 
Ugh I am just slow here. I feel bad when I can not grasp something.
 
Sorry I may sound confused but my problem is that I am starting out in
the form (breakdn) to begin with. There are a lot of variables set on
entry to this form. 
 
This is why I do not understand the line edit using firstform, I am
trying to close the 1st form and open the 2nd form. then reopen the 1st
form from this eep.
 
Next Dennis how does this get set to "Quit"  -  If vBtnFlag = 'Quit' 
 
And yes Dennis I may have to got 3-4 forms deep and come back to the 1st
form.
 
Tell me if I am wrong but based on this shouldn't I start out going to
the second for and then go back to the 1st form?
 
Help??
 
 
 


________________________________

From: [email protected] [mailto:[email protected]] On Behalf Of Dennis
McGrath
Sent: Monday, November 30, 2009 12:21 PM
To: RBASE-L Mailing List
Subject: [RBASE-L] - Re: saving data in form to table



My idea goes a little further and gives awesome control.

 

 

Label loop

Edit using firstform ..........

If vBtnFlag = 'Quit' then

   Goto done

Endif

 

If  vBtnFlag 'SecondForm' then

    Run similar code module for second form

endif

Goto loop

 

Label Done

Return

 

When the second form code exits you are taken right back to the first
form.

With care these modules can be used to drill down as deep as you want
and come back cleanly to each previous form.

 

Each form can have many button which among other this set the flag and
close the form.

Just make sure to handle the flag for each possible value.

 

Dennis McGrath

 

 

________________________________

From: [email protected] [mailto:[email protected]] On Behalf Of
[email protected]
Sent: Monday, November 30, 2009 11:09 AM
To: RBASE-L Mailing List
Subject: [RBASE-L] - Re: saving data in form to table

 

Yes, if you have that eep code in the SECOND form, then it will close
the
second form and return you back to the first form.   That's not what I
suggested.  Below is the code I suggested.  You don't do anything
special
in the second form.  The eep that opens up the second form will have
code
that sets the variable and then does a closewindow.

Karen

The eep code that calls up the second form

EDIT USING SecondForm
-- this code happens after you have exited the second form and want to
go back to the first form
SET VAR vFromSecond = 'yes'
CLOSEWINDOW -- this closes the first form
RETURN 





KAREN

Tried this and it is not working, just pops me back into the original
form.


SAVEROW
set var vBtnFlag = 'form2'
CLOSEWINDOW
RETURN

 


Reply via email to