|
Post by stefano on Sept 11, 2018 21:25:36 GMT
Am I right in stating that Just Basic has no way to split a program source code into multiple files? Since simplicity is a primary goal of JB, I fully understand there's no provisioning for modules/packages and things like that. But I would suggest to support as a minimum some kind of plain "include" directive... references: see AutoIt, a BASIC-like language for Windows, for the #include directive - www.autoitscript.com/autoit3/docs/intro/lang_directives.htmsee YaBasic, a language quite similar to JB, for import/export commands www.yabasic.de
|
|
|
Post by davidk64 on Jun 20, 2022 22:44:44 GMT
I came across this post searching for an answer to the same question. I guess no reply means there is no way to split a program source code into multiple files? Does LB allow it out of interest?
|
|
|
Post by tsh73 on Jun 21, 2022 8:08:45 GMT
No
but there is a freeware editor by Alyce Watson alycesrestaurant.com/workshop.htm that supports many additional things, among them
'include filename.bas (have read somewhere that it could not be *very first* line of a program, though) I wonder if one could tie JB to it.
I see lines "'** Created by Liberty BASIC Workshop " in code every now and then, so it is actually used by someone. Not using it myself - for simple stuff JB is enough, for big program I use Notepad++ (https://justbasiccom.proboards.com/thread/628/using-notepad-external-editor)
|
|
|
Post by Rod on Jun 21, 2022 8:18:22 GMT
Both Just BASIC and Liberty BASIC can split programs. The programs are held as .tkn files and one .tkn can be run from another .tkn or .bas program. No one does this because our computers are far more powerful and memory so large there is rarely a need. The other complication is sharing data between programs, we can't share arrays for example.
|
|
|
Post by davidk64 on Jun 21, 2022 9:57:54 GMT
Thanks for the replies chaps! I was interested because my current project is over 1000 lines now. I've been using control click to navigate to a sub definition but had forgotten about Alt-G - I think that will help a lot. I'm happy enough with all the code in one file - just didn't want to be missing out on splitting the code out of ignorance
|
|