BBS: Inland Empire Archive
Date: 03-14-92 (13:49) Number: 181
From: MARK BUTLER Refer#: NONE
To: WARREN MILLER Recvd: NO
Subj: MAKE LIBS Conf: (2) Quik_Bas
On 03-10-92 Warren Miller wrote to All...
WM> I don't want to sound to stupid but how do you make Librarys' and what
WM> can you place in them. I have several common routines and functions
WM> that I use, but the command to make libs eludes me. Also how do you
WM> use them in code?
WM> Also is there a standard in terms of code?
Compile your subs/functions to objs. Then...
LIB MYLIB +FIRST.OBJ +SECOND.OBJ +THIRD.OBJ;
This subject is covered quite well in the manual, for more details look
As far as "standards" goes the parameters you pass to the
subs/functions in your library need not have the exact same name(s) but
they must be the same type(s). For example, let's say you have a sub
called "SearchReplace" in your qlb. Even if it's in a qlb/lib you still
need to declare it at the head of your main module right? Like so....
DECLARE SUB SearchReplace (OldString$, NewString$, errcode%)
^^^^^^^^^^ ^^^^^^^^^^ ^^^^^^^^
| | |
when you call it you don't have to use these parameter names _but_ you
must use the same parameter types and in the same order. That is, when
you call this sub the parameter order and type MUST be
integer' right? These would be valid calls to your sub...
CALL SearchReplace (FoundStr$, ReplaceStr$, RetCode%)
CALL SearchReplace ("many", "mucho", returnerr%)
The following calls would NOT be valid...
CALL SearchReplace (RetCode%, FoundStr$, ReplaceStr$)
CALL SearchReplace (OldString$, NewString$)
CALL SearchReplace (OldString$, NewString$, errcode!)
[wrong numeric variable type]----------------+
In the above 3 examples the parameters are not listed in the correct
order or the parameter count is different or they are not the same
type. Does that help you out any?
--------------> MHB :-)
... OFFLINE 1.36 * PARANOID - One who is badly in touch with reality.
--- DB B1061/001271
* Origin: * Bare Bones BBS * (1:105/360)