Navigation: thinBasic language > Script structure > TBMain |
|
Default main function
thinBasic also implements a main function logic. If script contains a function called TBMain and during the script execution TBMain was not called by direct invocation, thinBasic will execute TBMain automatically.
TBMain is like the "main" function in C programming language.
Is TBMain mandatory?
No, it is not mandatory that a script contains a TBMain function.
I do not like TBMain name. Can I change it?
Yes, you can set up any script function as main function (at anytime during script execution) using APP_SetEntryPoint and APP_GetEntryPoint
© 2004-2008 thinBasic. All rights reserved. | Version 1.7.0.0 | Web Site: http://www.thinbasic.com |