Frank, I' going to have to vote with Bernie on this one.  I used to be a 
"stickler" for "goto-less" programming but past issues with "while loops" 
caused me to avoid the pain by judicious use of "goto" and especially "Quit to" 
to "clear the air" if you will.

I would prefer your suggestion but R:Base for all it's wonderful features has 
had problems with the deep nesting generated by strict structured programming.

Just my 2 cents.

:-)

Michael




Michael Moser
EXAQ Micro Services
www.exaq.com
Phone: 916-966-8313
Fax: 916-244-0582

 >>  Bernie,

 >>  Without wanting to start lecturing, isn't "quit-to" equivalent to getting
 >>  of
 >>  the motorway by driving of the shoulder, through the grassy area, over the
 >>  plants, and through the bushes straight into the garage? Similarly isn't
 >>  the
 >>  "goto" statement like crossing the median strip on the motorway and do a
 >>  u-turn? I have seen somebody doing this on the Super Motor Highway outside
 >>  Manila and as a result was stuck in a traffic jam for nearly 11 hours.

 >>  Point I am getting at is that I believe that these commands could cause
 >>  unpredictable shortcuts in your code and encourages spaghetti programming.
 >>  It may take a bit more code without using goto and quit-to constructs, but
 >>  believe me, longer term it makes the job of programming and maintenance
 >>  much
 >>  easier.


 >>  Frank van der Zwaag 



 >>  -----Original Message-----
 >>  From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Bernie
 >>  Corrigan
 >>  Sent: Thursday, 26 May 2005 10:19 a.m.
 >>  To: [email protected]
 >>  Subject: [RBG7-L] - Re: R:Base 7.5/7.1 creates 2 GB swap file onexit

 >>  David -

 >>  There are a number of places in my 6.5++ apps where I quit to the
 >>  current routine.  It clears all open IFs, WHILEs, and RUNs.  In fact it is
 >>  the only way I can get forms which have a lot of eeps to run properly when
 >>  the form is used in an iterative fashion.
 >>  Sounds to me like in 7.1 QUIT TO may no
 >>  longer be clearing the open processes.

 >>  Bernie



 >>  At 02:37 PM 5/25/2005 -0400, you wrote:
 >>  >Michael
 >>  >
 >>  >I assume we're LOOKING at MAIN.CMD?
 >>  >
 >>  >If so, it's defintely a no no to QUIT TO MAIN.CMD from within MAIN.CMD!!
 >>  >Why would you do that?  If you want it at that point to start over at 
 >>  >the beginning of the file, just add
 >>  >
 >>  >LABEL TOP at the top
 >>  >
 >>  >and replace
 >>  >
 >>  >QUIT TO MAIN.CMD with GOTO TOP
 >>  >
 >>  >QUIT TO MAIN.CMD belongs at the END of the sub-routines you call from 
 >>  >MAIN.CMD so it will return to the main menu program.
 >>  >
 >>  >David
 >>  >
 >>  >David Blocker
 >>  >[EMAIL PROTECTED]
 >>  >781-784-1919
 >>  >Fax: 781-784-1860
 >>  >Cell: 339-206-0261
 >>  >----- Original Message -----
 >>  >From: "Michael Moser" <[EMAIL PROTECTED]>
 >>  >To: "RBG7-L Mailing List" <[email protected]>
 >>  >Sent: Wednesday, May 25, 2005 1:48 PM
 >>  >Subject: [RBG7-L] - R:Base 7.5/7.1 creates 2 GB swap file on exit
 >>  >
 >>  >
 >>  >Here is an odd one - R:Base 7.1 or 7.5 running under XP Pro SP2
 >>  >
 >>  >This is part of a file that loops back on itself to redisplay a menu.  
 >>  >I have used this same process successfully in R:Base 6 without problems.
 >>  >
 >>  >If the "Quit to Main.cmd" is simply in the program and the "Exit" line 
 >>  >is executed, R:Base brings the system to it's knees for about 3 minutes 
 >>  >while 2 GB is written to the swap file then deleted.  Then all is back to
 >>  normal.
 >>  >
 >>  >if the "Quit to Main.cmd" line is commented out the "Exit" command 
 >>  >works fine, no delays.  I can't see a reason for this as the "Quit" 
 >>  >command is farther down in the code and should never be executed when 
 >>  >"EXIT" is executed.
 >>  >
 >>  >No database even needs to be connected so it is not a database issue.
 >>  >
 >>  >------------------------
 >>  >CLS
 >>  >
 >>  >CHOOSE vans +
 >>  >FROM +
 >>  >#LIST 'Safe Deposit,Box Inventory,Video Tapes,R> Prompt,Exit' + AT 
 >>  >CENTER CENTER CAPTION 'Record Selection'
 >>  >
 >>  >IF vans = '[ESC]' OR vans = 'R> Prompt' THEN
 >>  >  QUIT TO cleanup.cmd
 >>  >ENDIF
 >>  >
 >>  >IF vans = 'Exit' THEN
 >>  >  EXIT
 >>  >ENDIF
 >>  >
 >>  >-- other conditions here
 >>  >
 >>  >IF vans = 'Safe Deposit' THEN
 >>  >  QUIT TO safe.cmd
 >>  >ENDIF
 >>  >
 >>  >*(causes 2 GB to be written to the Swap file then deleted if the "EXIT"
 >>  >command above is executed.)
 >>  >QUIT TO main.cmd
 >>  >
 >>  >RETURN
 >>  >
 >>  >-----------------------
 >>  >
 >>  >Any thoughts?
 >>  >
 >>  >Thanks,
 >>  >Michael
 >>  >
 >>  >
 >>  >
 >>  >Michael Moser
 >>  >EXAQ Micro Services
 >>  >www.exaq.com
 >>  >Phone: 916-966-8313
 >>  >Fax: 916-244-0582
 >>  >
 >>  >
 >>  >

 >>  ____________________________________________________________________
 >>  CAUTION - This message may contain privileged and confidential 
 >>  information intended only for the use of the addressee named above.
 >>  If you are not the intended recipient of this message you are hereby 
 >>  notified that any use, dissemination, distribution or reproduction 
 >>  of this message is prohibited. If you have received this message in 
 >>  error please notify Air New Zealand immediately. Any views expressed 
 >>  in this message are those of the individual sender and may not 
 >>  necessarily reflect the views of Air New Zealand.
 >>  _____________________________________________________________________
 >>  For more information on the Air New Zealand Group, visit us online
 >>  at http://www.airnewzealand.com 
 >>  _____________________________________________________________________

Reply via email to