LB Booster
« !include »

Welcome Guest. Please Login or Register.
Jul 26th, 2017, 10:41am


Speed up Liberty BASIC programs by up to ten times!
Compile Liberty BASIC programs to compact, standalone executables!
Overcome many of Liberty BASIC's bugs and limitations!
LB Booster Resources
LB Booster documentation
LB Booster Home Page
LB Booster technical Wiki
Just BASIC forum
LB Umbrella forum
Liberty BASIC forum (the original)

« Previous Topic | Next Topic »
Pages: 1  Notify Send Topic Print
 thread  Author  Topic: !include  (Read 179 times)
Alincon
Full Member
ImageImageImage


member is offline

Avatar




PM


Posts: 143
xx !include
« Thread started on: Dec 13th, 2016, 01:13am »

I have used this successfully as last stmt in pgm
Code:
!include lb45func.bas 
 

But I am having problems trying to include other pieces of code.
I keep getting a 'mistake' error on the !include line.
I do put the !include in column one.
Does the module being included have to be in the LBB folder?
Are there restrictions on what code can be 'included'?
Can I include basic code that is in a file with a file extension other than 'bas'?
Any other things I may have missed in the documentation?

r.m.
User IP Logged

Richard Russell
Administrator
ImageImageImageImageImage


member is offline

Avatar




Homepage PM


Posts: 1247
xx Re: !include
« Reply #1 on: Dec 13th, 2016, 08:28am »

on Dec 13th, 2016, 01:13am, Alincon wrote:
I am having problems trying to include other pieces of code. I keep getting a 'mistake' error on the !include line.

You are using the wrong syntax: it's not !include but 'include: the initial character must be an apostrophe ('), not an exclamation point (!). This is so the directive appears as an ordinary comment to LB 4 and is ignored; Liberty BASIC Workshop uses the same syntax (although the include feature works somewhat differently).

Quote:
I do put the !include in column one.

In LBB v3.07 it is no longer necessary to start the 'include in column 1.

Quote:
Does the module being included have to be in the LBB folder? Are there restrictions on what code can be 'included'? Can I include basic code that is in a file with a file extension other than 'bas'?

None of those restrictions apply so long as you specify a full file path, name and extension.

Richard.
User IP Logged

Alincon
Full Member
ImageImageImage


member is offline

Avatar




PM


Posts: 143
xx Re: !include
« Reply #2 on: Dec 13th, 2016, 4:07pm »

Well, I've misread the obvious before and I'll probably do it again.
Thanks for setting me straight. Again.

r.m.
User IP Logged

Pages: 1  Notify Send Topic Print
« Previous Topic | Next Topic »

Donate $6.99 for 50,000 Ad-Free Pageviews!


This forum powered for FREE by Conforums ©
Sign up for your own Free Message Board today!
Terms of Service | Privacy Policy | Conforums Support | Parental Controls