home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.lang.visual.basic      MS Visual Basic discussions, NOT dot-net      10,840 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 8,887 of 10,840   
   kochs to All   
   Any ways to force the Program to halt?   
   16 Oct 04 11:17:51   
   
   XPost: comp.lang.basic.visual.misc   
   From: gm_assist@yahoo.com.sg   
      
   Hi, I have a problem here.   
      
   Referring to the following programming structure, is there a way to cause   
   the computer to overflow or stop  by inputting wrong values of intTime   
   and/or intDay? i.e. I don't want the program to jump to label NotWritten:.   
   but  want the program to stop working when the input values are of wrong   
   types.   
      
   Thanks a Million   
      
      
   ##   
   On Error GoTo NotWritten:   
   Open "c:\windows\system\aaa.txt" For Input As #f1   
       Line Input #f1, strJustStr1   
       Input #f1, intTime, intDay   
       Line Input #f1, strJustStr2   
   Close   
   If (intTime Mod 75) <> 0 Or (intDay Mod 79) <> 0 Then   
   .....   
   End If   
   ......   
   ......   
      
   NotWritten:   
   ... (other statements follow)   
      
   ##   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca