View Single Post
  #10 (permalink)  
Old 10-10-2009, 02:46 PM
agraham's Avatar
agraham agraham is offline
Basic4ppc Expert
 
Join Date: Jul 2007
Location: Cheshire, UK
Posts: 6,072
Awards Showcase
Innovator medal Beta Tester Forum Contributer 
Total Awards: 3
Default

This simple program returns the wrong result, without error, in the IDE but fails optimised comilation indicating that the error is on the "End Sub" of App_start whereas it's the semicolon at the end of the line in the For loop that is the problem.
Code:
Sub Globals
End Sub

Sub App_Start
    
Msgbox(DoMaths)
End Sub

Sub DoMaths
    
For i = 0 To 10 
        l = l + i;
    
Next
    
Return l
End Sub
__________________
Sorry, but I don't answer questions by PM or email.
Please post your queries in the forum.
Reply With Quote