QBasic / QB64 Discussion Forum      Other Subforums, Links and Downloads
 

 Return to Index  

The problem came from the copy to QB

November 23 2007 at 4:17 PM
Clippy  (Login burger2227)
R


Response to QB to Windows

 

When a routine uses a separate SUB program, and is pasted directly into the QB window header, sometimes the IDE tosses the SUB name into the SUB area and automatically adds END SUB before the end sub that you have already copied. Thus you have two END SUB's!

The IDE will tell you that you cannot have anything before the second END SUB. Just cut or delete out the second end sub line.

In any separate SUB routine, you can get that message also, if you try to put something before the SUB line at the beginning. Only a DEFINT  or other number type DEF can be there. Otherwise it will try to add a comment out ' mark.

An easier way is to copy the code into Notepad and save it as a BAS file. I have included an answer for Windows and Mac has shown a way using DOS.

Ted


 
 Respond to this message   
 Copyright © 1999-2014 Network54. All rights reserved.   Terms of Use   Privacy Statement