home *** CD-ROM | disk | FTP | other *** search
/ PC Online 1998 September / PCO_0998.ISO / filesbbs / dos / sbbs230b.exe / DOCS.LZH / BAJA.DOC < prev    next >
Encoding:
Text File  |  1996-04-26  |  180.1 KB  |  6,783 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.  
  14.  
  15.  
  16.  
  17.  
  18.                    Baja Version 2.10
  19.                Shell/Module Compiler for Synchronet BBS Software
  20.             Copyright 1996 Digital Dynamics
  21.                 Updated 03/24/96
  22.  
  23.  
  24.  
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.  
  32.  
  33.  
  34.  
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58. Table of Contents
  59. =================
  60.  
  61. Introduction.............................................................3
  62.     Source Files.....................................................4
  63.         BAJA.EXE.........................................................5
  64.         Modules..........................................................6
  65. Programming Syntax.......................................................7
  66.     Variables........................................................7
  67.     Arguments........................................................8
  68.     C Strings........................................................9
  69.     Integer Constants...............................................10
  70.     Command Key Constants...........................................11
  71.     Include Files...................................................14
  72.         Macro Definitions...............................................15
  73.     Global Variable Declarations....................................16
  74. Programming Style.......................................................17
  75.         Suggested Rules.................................................19
  76. Functions...............................................................21
  77.         String Manipulation.............................................22
  78.         Integer Manipulation............................................29
  79.         Logic/Control Flow..............................................32
  80.         Display.........................................................38
  81.         Input...........................................................45
  82.         Miscellaneous...................................................50
  83.         Mail............................................................65
  84.         Message Base....................................................67
  85.         File Base.......................................................70
  86.         Chat............................................................76
  87.         Information.....................................................77
  88.         File I/O........................................................79
  89.     File System.....................................................86
  90.     Directory System................................................88
  91. System Variables........................................................90
  92. Quick Function Reference................................................93
  93. Index..................................................................103
  94.  
  95.  
  96.  
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113. _______________________________________________________________________________
  114. Synchronet                            2                                Contents
  115.  
  116.  
  117. Introduction
  118. ============
  119.  
  120. Baja (pronounced bä'hä) is a high-level development tool used to create
  121. "command shells" and "loadable modules" for Synchronet BBS software. The
  122. programmable command and menu structure (PCMS) technology in Synchronet version
  123. 2 allows sysops to modify the user interface for the BBS by replacing or
  124. modifying command shells. Synchronet version 2.0 shipped with six stock command
  125. shells (Classic and Novice Synchronet shells as well as emulations of PCBoard,
  126. Wildcat, Major, and Renegade BBS packages). These shells can be modified,
  127. removed, or replaced with ease. Up to 500 shells can be made available to the
  128. users of the BBS with configurable security access to each shell via ARS (see
  129. the Synchronet Sysop manual for details on ARS).
  130.  
  131. Synchronet loadable modules are used to extend or customize the abilities of
  132. the BBS. Some modules are automatically loaded during specific events (login,
  133. logon, logoff, etc) while others may be executed at the request of a user
  134. (much like a door or other internal menu option).
  135.  
  136. Note:
  137.  
  138. If you come across an undefined term in this document, please read through
  139. the document to possibly find the term defined later or used again to clarify
  140. its meaning by context, or see the glossary in the Synchronet sysop manual.
  141.  
  142.  
  143.  
  144.  
  145.  
  146.  
  147.  
  148.  
  149.  
  150.  
  151.  
  152.  
  153.  
  154.  
  155.  
  156.  
  157.  
  158.  
  159.  
  160.  
  161.  
  162.  
  163.  
  164.  
  165.  
  166.  
  167.  
  168.  
  169.  
  170.  
  171.  
  172. _______________________________________________________________________________
  173. Synchronet                            3                            Introduction
  174.  
  175.  
  176. Source Files
  177. ============
  178.  
  179. Command shells and modules begin their life as a text source file (normally
  180. with a .SRC extension) or group of text files (including .INC files). These
  181. source files (and .INC files) can be edited with any ASCII text editor (e.g.
  182. EDIT, QEDIT, EDLIN, etc). The contents of the text file (often referred to as
  183. "source code") must conform to the Baja language specifications defined in this
  184. document. An extremely basic example of a command shell source file:
  185.  
  186. ----------------------------------[ Begin ]-----------------------------------
  187.  
  188. # EXAMPLE1.SRC
  189.  
  190. # Label for later "goto" commands
  191. :TOP
  192.  
  193. # Clear the screen
  194. CLS
  195.  
  196. # Show menu of commands
  197. MNEMONICS "~Comment to Sysop\r\n"
  198. MNEMONICS "~Goodbye (Logoff)\r\n"
  199.  
  200. # Show command prompt
  201. PRINT "\r\nCommand: "
  202.  
  203. # Get command key
  204. GETCMD "CG"
  205.  
  206. # Comment to sysop?
  207. COMPARE_KEY C
  208. IF_TRUE
  209.     SETSTR "1"
  210.         MAIL_SEND_FEEDBACK
  211.         GOTO TOP
  212.         END_IF
  213.  
  214. # Logoff?
  215. COMPARE_KEY G
  216. IF_TRUE
  217.         LOGOFF
  218.         GOTO TOP
  219.         END_IF
  220.  
  221. -----------------------------------[ End ]------------------------------------
  222.  
  223. The syntax of the above text will be explained later in this document.
  224.  
  225. For more examples of Baja source code, please see the *.SRC files in your
  226. Synchronet EXEC directory.
  227.  
  228.  
  229.  
  230.  
  231. _______________________________________________________________________________
  232. Synchronet                            4                     Intro: Source Files
  233.  
  234.  
  235. BAJA.EXE
  236. ========
  237.  
  238. After the source file has been created, BAJA.EXE is used to compile the .SRC
  239. file into a binary file with a .BIN extension that Synchronet can interpret
  240. and execute. If the source filename is EXAMPLE1.SRC, then the command line
  241. would be:
  242.  
  243.     BAJA EXAMPLE1
  244.  
  245. The compiler's output:
  246.  
  247. BAJA v2.00 · Synchronet Shell/Module Compiler · Copyright 1995 Digital Dynamics
  248.  
  249. Compiling EXAMPLE1.BIN...
  250. Resolving labels...
  251.  
  252. Done.
  253.  
  254. This creates the binary file EXAMPLE1.BIN.
  255.  
  256. Warning: Do not attempt to edit, view, or print .BIN files.
  257.  
  258. If the compile fails, an error message will be displayed with the filename that
  259. contains the error and the specific line number followed by a colon and the
  260. offending code.
  261.  
  262. Baja source (.SRC), include (.INC), and binary (.BIN) files as well as the Baja
  263. program itself are normally stored in the Synchronet EXEC directory. This is
  264. where Synchronet loads command shells and modules from, so the .BIN files must
  265. be created in or copied to this directory before they can be used.
  266.  
  267. After a command shell has been compiled, it must be added to the list of
  268. available command shells in SCFG (Synchronet Configuration program) to be
  269. available for the users to use. If using a multinode BBS, the other nodes
  270. must be re-run before the new command shell will be available on those nodes.
  271.  
  272. If modifying an existing command shell, SCFG does not need to be run and nodes
  273. do not have to be re-run since command shell binary files are dynamically
  274. loaded for each logon.
  275.  
  276.  
  277.  
  278.  
  279.  
  280.  
  281.  
  282.  
  283.  
  284.  
  285.  
  286.  
  287.  
  288.  
  289.  
  290. _______________________________________________________________________________
  291. Synchronet                            5                         Intro: BAJA.EXE
  292.  
  293.  
  294. Modules
  295. =======
  296.  
  297. Baja modules are very similar to command shells with the main difference being
  298. that they are not automatically loaded upon logon as command shells are
  299. (with the exception of login and logon modules). Instead, modules must be
  300. loaded from a command shell with the EXEC_BIN function described later in
  301. this document or launched as an external program or event configured in SCFG.
  302. Binary module files, like command shell binaries, must be located in the
  303. Synchronet EXEC directory.
  304.  
  305. Modules can be used to consolidate identical portions of multiple command
  306. shells into one binary that can be loaded from each command shell so that if a
  307. modification needs to be made to that portion, then only one source file needs
  308. to be modified and recompiled as opposed to making the same change to every
  309. command shell and recompiling them all. An example of this use is the STR_CMDS
  310. (string commands) module that is launched from multiple command shells.
  311.  
  312. Another use for modules is for third-party add-ons. Rather than distributing
  313. Baja source that must be merged into command shell source by sysops, developers
  314. can distribute module binaries that can be loaded directly from a command
  315. shell with a very small modification to the existing shells.
  316.  
  317. To load a Baja module in place of a DOS executable in SCFG, prepend an asterisk
  318. (*) to the name of the module (e.g. "*MYMOD") for the command line. If an
  319. argument is included on the command line (e.g. "*MYMOD %A") the contents
  320. will be automatically placed into the current command string for possible use
  321. by the module or functions there in.
  322.  
  323. To load a Baja module while displaying a message, menu file, or TEXT.DAT line
  324. (excluding lines containing % variables) use "@EXEC:MYMOD@", were MYMOD is the
  325. name of the module to execute. This is useful for executing modules in places
  326. where they cannot normally be loaded by event or command line. @-codes are
  327. only expanded in posts and e-mail if posted locally by user #1 (the sysop).
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334.  
  335.  
  336.  
  337.  
  338.  
  339.  
  340.  
  341.  
  342.  
  343.  
  344.  
  345.  
  346.  
  347.  
  348.  
  349. _______________________________________________________________________________
  350. Synchronet                            6                          Intro: Modules
  351.  
  352.  
  353. Programming Syntax
  354. ==================
  355.  
  356. Basics:
  357.         Execution always begins at the top of the source code and continues
  358.     downward until a function is executed which changes the flow of
  359.     execution. Only one function is allowed per line. The total length of
  360.     each line cannot exceed 1000 characters.
  361.  
  362. Whitespace:
  363.         All whitespace (TAB and SPACE characters) at the beginning of each line
  364.         are ignored. The first printable character of a line is considered
  365.         the first character. Completely blank lines are ignored.
  366.  
  367. Comments:
  368.         If the first character of a line is the pound symbol (#), the
  369.         line is ignored. These are normally used for text comments (remarks)
  370.     about the following source code line(s). Comments may be included on
  371.     the same lines as some (not all) functions, but in general it is
  372.     considered best to keep comments on their own lines as to not interfere
  373.     with proper Baja syntax. Comments are more easily read if there is a
  374.     space after the pound symbol (#) and before the comment text begins.
  375.  
  376. Labels:
  377.         If the first printable character of a line is a colon (:), the line is
  378.     considered a label to be used for the GOTO or CALL functions. Labels
  379.         are not case sensitive. There should be no space between the colon and
  380.     the name of the label. Label names may not contain spaces. Duplicate
  381.     label names within the same module or shell are disallowed.
  382.  
  383. Case Sensitivity:
  384.     Most elements of Baja syntax are not case sensitive (where upper or
  385.     lower case is significant). Functions, and variable names (for example)
  386.     are not case sensitve. Character constants ('A' for example) are case
  387.     sensitive.
  388.  
  389. Variables:
  390.         Variable names are not case sensitive and must begin with an alphabetic
  391.         character or an underscore (_). Variable names can be any length and
  392.     may contain alpha, numeric, and underscore characters only. The
  393.     variable name "str" is reserved to represent the current command string
  394.     and should not be used as a user defined variable name.
  395.  
  396.     When referencing a variable name defined by the system or another
  397.     module (global), the "!GLOBAL" compiler directive must be used to
  398.     declare the variable or the compiler will not recognize the variable
  399.     name and exit with a syntax error. Global variable declarations should
  400.     appear near the top of your source file.
  401.  
  402.     Baja modules that use variables require SBBS v2.2 or later.
  403.  
  404.  
  405.  
  406.  
  407.  
  408. _______________________________________________________________________________
  409. Synchronet                            7                      Programming Syntax
  410.  
  411.  
  412. Arguments:
  413.     When a function requires one or more arguments, there must some amount
  414.     of white space between the function name and each argument.
  415.  
  416.     In function definitions (in this document), required arguments are
  417.     listed in angled brackets (< >) and optional arguments are listed in
  418.     square brackets ([ ]). The actual bracket symbols are NOT used in the
  419.     source code. They are strictly for documentary purposes.
  420.  
  421.     When a string variable argument is specified in the definition of a
  422.     function, any string variable name (either local or global) may be
  423.     used. If str is used in the source code as the string variable name,
  424.     the current command string will be used in place of an actual
  425.     user or system string variable.
  426.  
  427.     An argument of # (pound sign) indicates an integer constant. The actual
  428.     pound sign is not used in the argument. See the section on Integer
  429.     Constants for more details.
  430.  
  431.     An argument of "str" (with double quotes) indicates a string constant
  432.     argument enclosed in double quotation marks. To place a double
  433.     quotation mark inside a string constant (as part of the actual string
  434.     constant), use \" instead of just " where you want the quotation mark
  435.     to appear in the string.
  436.  
  437.     An argument of "cstr" (with double quotes) indicates a C string
  438.     constant argument enclosed in double quotation marks. See the next
  439.     section on C strings for the definition of the contents.
  440.  
  441.     See the beginning of the Functions section for the complete definition
  442.     of all argument types and how they're specified in function
  443.     definitions.
  444.  
  445.  
  446.  
  447.  
  448.  
  449.  
  450.  
  451.  
  452.  
  453.  
  454.  
  455.  
  456.  
  457.  
  458.  
  459.  
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466.  
  467. _______________________________________________________________________________
  468. Synchronet                            8                      Programming Syntax
  469.  
  470.  
  471. C Strings:
  472.  
  473.     Some character string arguments are defined as being C type (cstr).
  474.     This indicates the contents of the string use the same special/control
  475.     character escape sequences as defined for the printf() function in the
  476.     ANSI definition of the C programming language. The only exception to
  477.     the ANSI definition, is that \### defines a character value in decimal
  478.     (base 10), not octal (base 8). All escape sequences begin with the
  479.     backslash (\) character. The valid escape sequences are:
  480.  
  481.         \\      Backslash
  482.         \?      Question mark
  483.         \'      Single quote
  484.         \"      Double quote
  485.         \r      Carriage return
  486.         \n      Line feed
  487.         \t      Horizontal tab
  488.         \b      Backspace
  489.         \a      Bell
  490.         \f      Formfeed
  491.         \v      Vertical tab
  492.         \###    Character value in decimal
  493.         \x##    Character value in hexadecimal
  494.  
  495.     The text string must be enclosed in double quote (") symbols. Example:
  496.  
  497.         "Hello, world.\r\n"
  498.  
  499.     To include an actual back-slash (\) character in a C string, you must
  500.     prefix the back-slash with another back-slash. Example:
  501.  
  502.         "C:\README.TXT"
  503.  
  504.     would be an invalid path and filename.
  505.  
  506.         "C:\\README.TXT"
  507.  
  508.     would be the correct C string to represent C:\README.TXT.
  509.  
  510.  
  511.  
  512.  
  513.  
  514.  
  515.  
  516.  
  517.  
  518.  
  519.  
  520.  
  521.  
  522.  
  523.  
  524.  
  525.  
  526. _______________________________________________________________________________
  527. Synchronet                            9                      Programming Syntax
  528.  
  529.  
  530. Integer Constants:
  531.  
  532.     Many functions allow or require the use of integer constants (as
  533.     opposed to integer variables). An integer constant is a number that is
  534.     "hard-coded" into the resulting executable file and will remain
  535.     constant (never change) from that point on.
  536.  
  537.     You can specify integer constants in many ways:
  538.  
  539.     Representation        Range                Examples
  540.     --------------        -----                --------
  541.     Decimal (base 10)    -2147483648 to 2147483647    0, 10, -25
  542.     Hexadecimal (base 16)    0x0 to 0xffffffff        0x7f, 0xA69B
  543.     Octal (base 8)        00 to 037777777777        0377, 0505
  544.     Bit value        .0 to .31            .0, .1, .15
  545.     ASCII value        '' to '■'                      'A', ' ', '%'
  546.     Special char        '\r' to '\v' (see C Strings)    '\r', '\n'
  547.  
  548.     Constants can be modified during specification (no variables may be
  549.     used in the modification). No space is allowed between the numeric
  550.     constant and the modifier symbol. Valid modifiers:
  551.  
  552.     Symbol            Operation            Example
  553.     ------            ---------            -------
  554.     +            Addition            10+2
  555.     -            Subtraction            20-8
  556.     *            Multiplication            4*3
  557.     /            Division            36/3
  558.     %            Modulus (remainder)        53%8
  559.     &            Bit-wise AND            695&0x1f
  560.     |            Bit-wise OR            0x10|8
  561.     ~            Bit-wise NOT            ~3
  562.     ^            Bit-wise XOR (exclusive OR)    0xff^12
  563.     >>            Right shift            03700>>4
  564.     <<            Left shift            255<<2
  565.  
  566.  
  567.  
  568.  
  569.  
  570.  
  571.  
  572.  
  573.  
  574.  
  575.  
  576.  
  577.  
  578.  
  579.  
  580.  
  581.  
  582.  
  583.  
  584.  
  585. _______________________________________________________________________________
  586. Synchronet                           10                      Programming Syntax
  587.  
  588.  
  589. Command Key Constants:
  590.  
  591.     Some functions require the use of a command key constant. A command key
  592.     constant is a keyword or symbol representing a valid command selected
  593.     by a user.
  594.  
  595.     The simplest way to specify a command key constant, is to simply
  596.     type the key that you wish to use for a specific command. Example:
  597.  
  598.         CMDKEY A
  599.  
  600.     Would use the 'A' key for the command key constant. Simply specifying
  601.     a letter does not indicate case sensitivy (i.e. the above example
  602.     could have been "CMDKEY a" with the same results). 
  603.  
  604.     To specify a specific case (upper or lower), you must prefix the
  605.     command key with a single quote symbol ('). Example:
  606.  
  607.         CMDKEY 'a
  608.  
  609.  
  610.  
  611.  
  612.  
  613.  
  614.  
  615.  
  616.  
  617.  
  618.  
  619.  
  620.  
  621.  
  622.  
  623.  
  624.  
  625.  
  626.  
  627.  
  628.  
  629.  
  630.  
  631.  
  632.  
  633.  
  634.  
  635.  
  636.  
  637.  
  638.  
  639.  
  640.  
  641.  
  642.  
  643.  
  644. _______________________________________________________________________________
  645. Synchronet                           11                      Programming Syntax
  646.  
  647.  
  648.     To specify a control character (like Ctrl-H, which is a backspace),
  649.     you must prefix the control character (in upper case) with a caret
  650.     (^) symbol. Example:
  651.  
  652.         CMDKEY ^H
  653.  
  654.     Valid control character specifications:
  655.  
  656.         ^A    Attribute/color code (internal line editor)
  657.         ^B    Beginning of line (internal line editor)
  658.         ^C    Abort
  659.         ^D    Delete word right (internal line editor)
  660.         ^E    End of line (internal line editor)
  661.         ^F    Forward cursor (Right arrow key)
  662.         ^G    Beep
  663.         ^H    Backspace
  664.         ^I    Tab
  665.         ^J    Line feed (Down arrow key)
  666.         ^K    Ctrl-key help menu
  667.         ^L    Form feed (Clear screen)
  668.         ^M    Carriage return (Enter key)
  669.         ^N    Next word (internal line editor)
  670.         ^O    Temp pause toggle
  671.         ^P    Private message
  672.         ^Q    Un-pause
  673.         ^R    Redraw line (internal line editor)
  674.         ^S    Pause
  675.         ^T    Time info
  676.         ^U    List users online
  677.         ^V    Center line (internal line editor)
  678.         ^W    Delete word left (interal line editor)
  679.         ^X    Delete line (internal line editor)
  680.         ^Y    Delete to end-of line (internal line editor)
  681.         ^Z    Raw input mode toggle
  682.         ^]    Back cursor (Left arrow key)
  683.         ^[    Escape (Esc key)
  684.         ^^    Up cursor (Up arrow key)
  685.  
  686.     You may also specify special control characters (carriage return,
  687.     form feed, etc) be prepending a backslash (i.e. \r, \f, etc). See the
  688.     section on C strings for details.
  689.  
  690.  
  691.  
  692.  
  693.  
  694.  
  695.  
  696.  
  697.  
  698.  
  699.  
  700.  
  701.  
  702.  
  703. _______________________________________________________________________________
  704. Synchronet                           12                      Programming Syntax
  705.  
  706.  
  707.     Some command key input functions allow the use of slash-commands
  708.     (command keys prepended with a slash character, i.e. /A). The two
  709.     character slash-commands are the only multi-character commands
  710.     supported by command key functions. Example:
  711.  
  712.         CMDKEYE /A
  713.  
  714.     Is valid, but:
  715.  
  716.         CMDKEYE -A
  717.  
  718.     Is not valid.
  719.  
  720.     To test specifically for digit (0-9) command keys and slash-digit
  721.     command keys (/0-/9), use DIGIT and EDIGIT respectively. Example:
  722.  
  723.         CMDKEYE DIGIT
  724.  
  725.     To test if the user hit a key from 0 to 9, or:
  726.  
  727.         CMDKEYE EDIGIT
  728.  
  729.     To test if the user hit a slash-key combination from /0 to /9.
  730.  
  731.     You may, of course, also test for a specific digit command key:
  732.  
  733.         CMDKEYE 1
  734.     and
  735.         CMDKEYE /1
  736.  
  737.     are both valid command key constants.
  738.  
  739.     To specify # for a command key, use '# (otherwise # will be interpreted
  740.     as the beginning of a comment).
  741.  
  742.     To specify SPACE bar for the command key, use ' ', example:
  743.  
  744.         CMDKEY ' '
  745.  
  746.     Extended ASCII characters (Ç for example) are not valid command keys.
  747.  
  748.  
  749.  
  750.  
  751.  
  752.  
  753.  
  754.  
  755.  
  756.  
  757.  
  758.  
  759.  
  760.  
  761.  
  762. _______________________________________________________________________________
  763. Synchronet                           13                      Programming Syntax
  764.  
  765.  
  766. Include Files
  767. =============
  768.  
  769. Source code segments that are to be shared amoung multiple command shells or
  770. modules can be placed into a separate text file (preferrably with a .INC
  771. extension) and included in the source code for multiple modules by using the
  772. "!INCLUDE" compiler directive to specify the filename to include. Example:
  773.  
  774. !INCLUDE MYDEFS.INC
  775.  
  776. This is useful when including files supplied by Digital Dynamics or third
  777. party developers to pre-define constants (macros), common sub-routines, or
  778. variable definitions. The following include files are distributed with Baja
  779. (and should not be modified):
  780.  
  781. ERRNO.INC    Definitions for possible values of _ERRNO system variable
  782. FILE_IO.INC    Constants for use with file I/O functions
  783. DIR_ATTR.INC    Constants for use with SET_FILE_ATTR & GET_FILE_ATTR functions
  784. USERDEFS.INC    Synchronet User constants for use with various functions
  785. NODEDEFS.INC    Synchronet Node constants for use with various functions
  786. SBBSDEFS.INC    Synchronet system variable declarations and constants
  787.         (automatically includes USERDEFS.INC and NODEDEFS.INC)
  788.  
  789. Take care not to include the same file more than once in the same source code.
  790. It is suggested you put all of your !include statements near the top of your
  791. source file. If you include a file that in-turn includes other files
  792. (SBBSDEFS.INC, for example, includes USERDEFS.INC and NODEDEFS.INC), you
  793. do not need to include the other files. If you !include SBBSDEFS.INC, you
  794. DO NOT need to !incluce NODEDEFS.INC and USERDEFS.INC as well. Take care not
  795. to nest include files too deeply or the compilation will fail.
  796.  
  797. This compiler directive is very similar to the "#include" directive used by
  798. C compilers, but if a specific path is not specified, only the current
  799. directory will be searched for the file to include.
  800.  
  801.  
  802.  
  803.  
  804.  
  805.  
  806.  
  807.  
  808.  
  809.  
  810.  
  811.  
  812.  
  813.  
  814.  
  815.  
  816.  
  817.  
  818.  
  819.  
  820.  
  821. _______________________________________________________________________________
  822. Synchronet                           14                           Include Files
  823.  
  824.  
  825. Macro Definitions
  826. =================
  827.  
  828. Commonly used character strings and integer constants can be specified as
  829. macros by using the "!DEFINE" compiler directive to specify the macro name to
  830. use and the value of the macro. Example:
  831.  
  832. !DEFINE MAXIMUM_USERS 250
  833.  
  834. Now, any place you might want to use the number 250 in your Baja source, you
  835. can use the macro "MAXIMUM_USERS" instead. This makes changing the value of
  836. the numeric or character string constant very easy.
  837.  
  838. This compiler directive is very similar to the "#define" directive used by
  839. C compilers with the main exception being that the macro name is not case
  840. sensitive.
  841.  
  842.  
  843.  
  844.  
  845.  
  846.  
  847.  
  848.  
  849.  
  850.  
  851.  
  852.  
  853.  
  854.  
  855.  
  856.  
  857.  
  858.  
  859.  
  860.  
  861.  
  862.  
  863.  
  864.  
  865.  
  866.  
  867.  
  868.  
  869.  
  870.  
  871.  
  872.  
  873.  
  874.  
  875.  
  876.  
  877.  
  878.  
  879.  
  880. _______________________________________________________________________________
  881. Synchronet                           15                       Macro Definitions
  882.  
  883.  
  884. Global Variable Declarations
  885. ============================
  886.  
  887. When using variables defined by the system (see System Variables) or another
  888. shell or module (see GLOBAL_STR and GLOBAL_INT functions), you must first
  889. declare these variables using the "!GLOBAL" compiler directive. Example:
  890.  
  891. !GLOBAL SOME_GLOBAL_VAR
  892.  
  893. Multiple global variables may be declared with one !GLOBAL statement:
  894.  
  895. !GLOBAL SOME_GLOBAL_VAR ANOTHER_GLOBAL_VAR
  896.  
  897. If you attempt to use a global variable without first delcaring it, the
  898. compiler will fail to compile the source with an "expected variable name"
  899. syntax error message.
  900.  
  901. This compiler directive is very similar to the "extern" keyword used by C
  902. compilers.
  903.  
  904.  
  905.  
  906.  
  907.  
  908.  
  909.  
  910.  
  911.  
  912.  
  913.  
  914.  
  915.  
  916.  
  917.  
  918.  
  919.  
  920.  
  921.  
  922.  
  923.  
  924.  
  925.  
  926.  
  927.  
  928.  
  929.  
  930.  
  931.  
  932.  
  933.  
  934.  
  935.  
  936.  
  937.  
  938.  
  939. _______________________________________________________________________________
  940. Synchronet                           16            Global Variable Declarations
  941.  
  942.  
  943. Programming Style
  944. =================
  945.  
  946. As stated in the previous section, white space characters at the beginning
  947. of a line are ignored and have no effect on the resulting compilation. But,
  948. whitespace can be very useful in making the source code readable by indenting
  949. conditional blocks of code, and using blank lines to separate blocks of
  950. related code. Comments are also very helpful in making the code readable.
  951.  
  952. Compare the following source to the example given in the Source Files chapter:
  953.  
  954. ----------------------------------[ Begin ]-----------------------------------
  955.  
  956. :TOP
  957. CLS
  958. MNEMONICS "~Comment to Sysop\r\n"
  959. MNEMONICS "~Goodbye (Logoff)\r\n"
  960. PRINT "\r\nCommand: "
  961. GETCMD "CG"
  962. COMPARE_KEY C
  963. IF_TRUE
  964. SETSTR "1"
  965. MAIL_SEND_FEEDBACK
  966. GOTO TOP
  967. END_IF
  968. COMPARE_KEY G
  969. IF_TRUE
  970. LOGOFF
  971. GOTO TOP
  972. END_IF
  973.  
  974. -----------------------------------[ End ]------------------------------------
  975.  
  976. Without the whitespace and the comments, the code appears much more cryptic
  977. (the control flow is hard to follow). But the code will compile into exactly
  978. the same binary file as the earlier example.
  979.  
  980.  
  981.  
  982.  
  983.  
  984.  
  985.  
  986.  
  987.  
  988.  
  989.  
  990.  
  991.  
  992.  
  993.  
  994.  
  995.  
  996.  
  997.  
  998. _______________________________________________________________________________
  999. Synchronet                           17                       Programming Style
  1000.  
  1001.  
  1002. Consider this more elaborate example using indentation only:
  1003.  
  1004. With indentation:
  1005.  
  1006. ----------------------------------[ Begin ]-----------------------------------
  1007.  
  1008. COMPARE_ARS FILE_CMDS=0
  1009. IF_TRUE
  1010.     COMPARE_USER_MISC UM_ASK_NSCAN
  1011.         IF_TRUE
  1012.                 YES_NO "\r\n\r\nSearch all libraries for new files"
  1013.                 IF_TRUE
  1014.                         FILE_NEW_SCAN_ALL
  1015.                         END_IF
  1016.                 END_IF
  1017.         END_IF
  1018.  
  1019. -----------------------------------[ End ]------------------------------------
  1020.  
  1021. Without indentation:
  1022.  
  1023. ----------------------------------[ Begin ]-----------------------------------
  1024.  
  1025. COMPARE_ARS FILE_CMDS=0
  1026. IF_TRUE
  1027. COMPARE_USER_MISC UM_ASK_NSCAN
  1028. IF_TRUE
  1029. YES_NO "\r\n\r\nSearch all libraries for new files"
  1030. IF_TRUE
  1031. FILE_NEW_SCAN_ALL
  1032. END_IF
  1033. END_IF
  1034. END_IF
  1035.  
  1036. -----------------------------------[ End ]------------------------------------
  1037.  
  1038. As you can see without the indentation, you can get lost in nested IF
  1039. statements trying to understand how the code will execute.
  1040.  
  1041. While you may have known quite well what you intended to accomplish and how
  1042. you expected the code to execute at the time of writing it, it would be much
  1043. harder to understand how the code was expected to execute at a later date
  1044. (or by another person) if a consistent indentation style was not used.
  1045.  
  1046.  
  1047.  
  1048.  
  1049.  
  1050.  
  1051.  
  1052.  
  1053.  
  1054.  
  1055.  
  1056.  
  1057. _______________________________________________________________________________
  1058. Synchronet                           18                       Programming Style
  1059.  
  1060.  
  1061. Suggested Rules of Style
  1062. ========================
  1063.  
  1064. There isn't a "right" or "wrong" way to use indentation, blank lines,
  1065. or comments, but we will present a set of suggested "rules" here. If you decide
  1066. you prefer another style, that is fine. The most important thing is that you
  1067. are consistent in your use of whatever style you choose.
  1068.  
  1069. Top of File Comments
  1070. --------------------
  1071. Place a comment as the very first line of the file with the name of the .SRC
  1072. file. Example:
  1073.  
  1074. # EXAMPLE.SRC
  1075.  
  1076. Then a block of comment lines that describe what the shell or module's purpose
  1077. is, who programmed it, when, where, etc.
  1078.  
  1079. Label Comments
  1080. --------------
  1081. Labels normally represent the beginning of a sub-routine and should be
  1082. well commented. A graphical line to show the beginning of a new sub-routine
  1083. is often helpful. Example:
  1084.  
  1085. ############################### My Sub-routine ################################
  1086. :MY-SUB
  1087.  
  1088. CMD_HOME Comments
  1089. -----------------
  1090. The CMD_HOME function marks the beginning of a command/menu loop and should
  1091. be well commented. Example:
  1092.  
  1093. #############
  1094. # MAIN MENU #
  1095. #############
  1096. CMD_HOME
  1097.  
  1098.  
  1099.  
  1100.  
  1101.  
  1102.  
  1103.  
  1104.  
  1105.  
  1106.  
  1107.  
  1108.  
  1109.  
  1110.  
  1111.  
  1112.  
  1113.  
  1114.  
  1115.  
  1116. _______________________________________________________________________________
  1117. Synchronet                           19                Suggested Rules of Style
  1118.  
  1119.  
  1120. Conditional Indentation
  1121. -----------------------
  1122. Whenever a block of code is conditionally executed (only executed under
  1123. specific conditions), the block of code should be indented one tabstop past
  1124. the block header (IF_TRUE, IF_FALSE, ELSE, SWITCH, CASE, CMDKEY, CMDSTR, etc).
  1125. The block of code to be indented includes the block terminator (END_IF,
  1126. END_CMD, END_CASE, END_SWITCH, etc). Example:
  1127.  
  1128. GETCMD "ABCD"
  1129.  
  1130. CMDKEY A
  1131.         COMPARE_ARS LEVEL 50
  1132.         IF_TRUE
  1133.                 PRINT "You have level 50 or higher.\r\n"
  1134.         ELSE
  1135.                 PRINT "You have level 49 or lower.\r\n"
  1136.                 END_IF
  1137.         END_CMD
  1138.  
  1139. Separate Code Blocks
  1140. --------------------
  1141. Use blank lines to separate medium to large code blocks from other code
  1142. (most especially CMDKEY, CMDKEYS, CMDSTR, and SWITCH code blocks). Example:
  1143.  
  1144. GETCMD "ABCD"
  1145.  
  1146. CMDKEY A
  1147.         PRINT "You hit A.\r\n"
  1148.         END_CMD
  1149.  
  1150. CMDKEY B
  1151.         PRINT "You hit B.\r\n"
  1152.         END_CMD
  1153.  
  1154. End of File Comment
  1155. -------------------
  1156. Place a comment at the end of the file. Example:
  1157.  
  1158. # End of EXAMPLE.SRC
  1159.  
  1160.  
  1161.  
  1162.  
  1163.  
  1164.  
  1165.  
  1166.  
  1167.  
  1168.  
  1169.  
  1170.  
  1171.  
  1172.  
  1173.  
  1174.  
  1175. _______________________________________________________________________________
  1176. Synchronet                           20                Suggested Rules of Style
  1177.  
  1178.  
  1179. Function Definitions
  1180. ====================
  1181.  
  1182. The remainder of this document is for defining the correct use of all Baja
  1183. functions. If you wish to look up a specific function by subject, please refer
  1184. to the table of contents or the quick reference at the end of the document.
  1185.  
  1186. Argument Types
  1187. --------------
  1188. Each function definition will begin with the name of the function followed by
  1189. all possible arguments (parameters) and the type of each argument. The possible
  1190. argument types are:
  1191.  
  1192. Type        Description
  1193. ~~~~        ~~~~~~~~~~~
  1194. "str"           String constant (contained in double quotes)
  1195. "cstr"          C string constant (contained in double quotes)
  1196. txt        String constant (no quotes)
  1197. #        Integer constant (the # symbol is not part of the syntax)
  1198. str_var     String variable name or 'str' for current command string
  1199. int_var     Integer variable name
  1200. any_var     Any string or integer variable name
  1201. char        Character constant (single character, no quotes)
  1202. key        Command key constant
  1203. keylist     List of command key constants (no space between each key)
  1204.  
  1205. Each argument type is contained in either angled brackets (< and >) to indicate
  1206. the argument is required, or square brackets ([ and ]) to indicate the
  1207. argument is optional. An argument of [...] indicates a variable number of
  1208. optional arguments of the last specified type. Example:
  1209.  
  1210.     SPRINTF <str_var> <"cstr"> <any_var> [any_var] [...]
  1211.  
  1212. This function definition indicates that the SPRINT function requires a minimum
  1213. of three arguments: a string variable, a C string constant, and one or more
  1214. variables of either integer or string type.
  1215.  
  1216. Required Include Files
  1217. ----------------------
  1218. Following the function argument types, may be one or more required include
  1219. (.INC) files. If any files are listed on the same line as the function
  1220. (to the right of the page), these files must be included at the top of
  1221. your source file to use this function arguments correctly. Example:
  1222.  
  1223.     !INCLUDE NODEDEFS.INC
  1224.  
  1225. Do not include the same file more than once in the same source file. Once
  1226. is enough, and it should be done so near the top of your source (.SRC) file.
  1227.  
  1228. Argument Names
  1229. --------------
  1230. If any arguments are allowed for a function, a list of argument names will
  1231. follow the text "args:" below the function name and argument list. This will
  1232. help in referencing the individual arguments in the function description.
  1233.  
  1234. _______________________________________________________________________________
  1235. Synchronet                           21                Suggested Rules of Style
  1236.  
  1237.  
  1238. String Manipulation Functions
  1239. =============================
  1240.  
  1241. Functions used for manipulating string variables (global or local) and/or the
  1242. current command string.
  1243.  
  1244.  STR <str_var> [str_var] [...]
  1245. args: new_vars
  1246. ------------------------------
  1247. Define one or more local string variables for later use. The new_vars arguments
  1248. are the names of the variables to define. These names must not be currently
  1249. used by other variables (local or global).
  1250.  
  1251. The variable name "str" is used by other functions to refer to the current
  1252. command string, and therefore cannot be used as a user defined variable name.
  1253.  
  1254. After definition, the variable names can be used by other functions. The
  1255. variables will each be initialized to a null string. The variables can only be
  1256. referenced in the current shell or module. When the current shell or module is
  1257. terminated, the variable names and their contents are lost. If you wish to
  1258. retain a variable name and its contents between shells or modules, use a global
  1259. variable instead of a local variable.
  1260.  
  1261. GLOBAL_STR <str_var> [str_var] [...]
  1262.       args: new_vars
  1263. ------------------------------------
  1264. Define one or more global string variables for later use. The arguments are the
  1265. names of the variables to define. Each variable name must not be currently used
  1266. by another variable (local or global). Global variable names and their contents
  1267. are not disposed of until the current user logs off the BBS.
  1268.  
  1269.  SET <str_var> <"cstr">
  1270. args: dest      value
  1271. -----------------------
  1272. Writes to the string variable dest, the contents of the C string specified as
  1273. value. This function is the Baja equivalent of the standard C strcpy() function
  1274. with the exception that the source must be a string constant. Example:
  1275.  
  1276.     STR USER_NAME
  1277.     SET USER_NAME "John Doe"
  1278.  
  1279. When writing to the current command string, use the SETSTR function instead
  1280. of this function for best optimization.
  1281.  
  1282.  
  1283.  
  1284.  
  1285.  
  1286.  
  1287.  
  1288.  
  1289.  
  1290.  
  1291.  
  1292.  
  1293. _______________________________________________________________________________
  1294. Synchronet                           22           String Manipulation Functions
  1295.  
  1296.  
  1297. COPY <str_var> <any_var>
  1298. args: dest      source
  1299. ------------------------
  1300. Copies the source variable (string or integer) into the specified destination
  1301. variable. This function is the Baja equivalent of the standard C strcpy()
  1302. function with the exception that the source must be a variable, but may be
  1303. either of integer or string type. Example:
  1304.  
  1305.     # define two variables
  1306.     STR VAR1 VAR2
  1307.     # copy some text into the first variable
  1308.     SET VAR1 "Some Text"
  1309.     # copy that variable into the second variable
  1310.     COPY VAR2 VAR1
  1311.     # display the contents of second variable
  1312.     PRINT VAR2
  1313.  
  1314. If the source variable is an integer variable, it is converted into
  1315. a decimal (base 10) string before the copy is executed. Use SPRINTF if you
  1316. want to convert an integer variable into a string using hexadecimal (base 16)
  1317. or octal (base 8) representation instead of decimal.
  1318.  
  1319. SWAP <str_var> <any_var>
  1320. args: var1      var2
  1321. ------------------------
  1322. Exchanges the contents of two string variables, or a string variable and an
  1323. integer variable. The first argument (var1) is the name of a string variable
  1324. and the second argument (var2) is the name of a string or integer variable.
  1325. If var2 is an integer variable, var1 will be set to the decimal representation
  1326. of the integer variable contents and var2 will be set the integer
  1327. representation of var1 (specified in hex, octal, or decimal). Example:
  1328.  
  1329.     INT I
  1330.     STR S
  1331.  
  1332.     # set S to 100h (256)
  1333.     SET S "0x100"
  1334.     # set I to 100
  1335.     SET I 100
  1336.     # swap them
  1337.     SWAP S I
  1338.     # I now equals 256 and S is "100"
  1339.  
  1340.  
  1341.  
  1342.  
  1343.  
  1344.  
  1345.  
  1346.  
  1347.  
  1348.  
  1349.  
  1350.  
  1351.  
  1352. _______________________________________________________________________________
  1353. Synchronet                           23           String Manipulation Functions
  1354.  
  1355.  
  1356. STRCAT <str_var> <str_var or "cstr">
  1357.   args: dest      source
  1358. ------------------------------------
  1359. Concatenates (appends) the contents of a string variable (specified as dest)
  1360. with the contents of a C string or string variable specified as source. This
  1361. function is the Baja equivalent of the standard C strcat() function.
  1362.  
  1363. SPRINTF <str_var> <"cstr"> <any_var> [any_var] [...]
  1364.    args: dest       format   variables
  1365. ----------------------------------------------------
  1366. Writes the specified variables into the string variable (dest) based on
  1367. the specified format. This function is the same as PRINTF except that the
  1368. output is written into the dest string variable instead of the console. This
  1369. function is the Baja equivalent of the standard C sprintf() function with
  1370. the exception that all the arguments following the format must be variables
  1371. (no constants allowed). See the PRINTF function definition for details.
  1372.  
  1373. TIME_STR <str_var> <int_var>
  1374.     args: dest        time
  1375. ----------------------------
  1376. Writes to the string variable (specified as dest) the time and date stored in
  1377. the integer variable specified by time. This function is the Baja equivalent
  1378. to the standard C ctime() function. Example:
  1379.  
  1380.     # Display current time
  1381.     INT T
  1382.     TIME T
  1383.     TIME_STR STR T
  1384.     PRINTF "Current time: %s\r\n" STR
  1385.  
  1386. Would display the current date/time similar to:
  1387.  
  1388.     Current time: Thu Aug 31 1995 08:34 am
  1389.  
  1390. DATE_STR <str_var> <int_var>
  1391.     args: dest        time
  1392. ----------------------------
  1393. Writes to the string variable (specified as dest) the date stored in the
  1394. integer variable specified by time (obtained with TIME or similar function) in
  1395. MM/DD/YY format or DD/MM/YY format if European date format is enabled in SCFG.
  1396. Example:
  1397.  
  1398.     # Display current date
  1399.     INT T
  1400.     TIME T
  1401.     DATE_STR STR T
  1402.     PRINTF "Current date: %s\r\n" STR
  1403.  
  1404. Would display the current date similar to:
  1405.  
  1406.     Current date: 08/31/95
  1407.  
  1408.  
  1409.  
  1410.  
  1411. _______________________________________________________________________________
  1412. Synchronet                           24           String Manipulation Functions
  1413.  
  1414.  
  1415. SECOND_STR <str_var> <int_var>
  1416.       args: dest      seconds
  1417. ------------------------------
  1418. Writes to the string variable (specified as dest) the number of seconds
  1419. (in HH:MM:SS format) stored in the integer variable specified by seconds.
  1420. Example:
  1421.  
  1422.     # Display number of seconds elapsed
  1423.     INT START END
  1424.     TIME START
  1425.     PRINT "Wait a period of time, then hit a key..."
  1426.     GETKEY
  1427.     TIME END
  1428.     SUB END START
  1429.     SECOND_STR STR END
  1430.     PRINTF "\r\n%s time elapsed.\r\n" STR
  1431.  
  1432.  
  1433.  
  1434.  
  1435.  
  1436.  
  1437.  
  1438.  
  1439.  
  1440.  
  1441.  
  1442.  
  1443.  
  1444.  
  1445.  
  1446.  
  1447.  
  1448.  
  1449.  
  1450.  
  1451.  
  1452.  
  1453.  
  1454.  
  1455.  
  1456.  
  1457.  
  1458.  
  1459.  
  1460.  
  1461.  
  1462.  
  1463.  
  1464.  
  1465.  
  1466.  
  1467.  
  1468.  
  1469.  
  1470. _______________________________________________________________________________
  1471. Synchronet                           25           String Manipulation Functions
  1472.  
  1473.  
  1474. FTIME_STR <str_var> <"cstr"> <int_var>
  1475.      args: dest      format   time
  1476. --------------------------------------
  1477. Writes to the string variable (specified as dest) the date and time information
  1478. from the integer variable (specified as time) formatted according to string
  1479. constant specified as format. The format characters are described below:
  1480.  
  1481.     %a    abbreviated weekday name
  1482.     %A    full weekday name
  1483.     %b    abbreviated month name
  1484.     %B    full month name
  1485.     %c    date and time
  1486.     %d    day of month (01-31) (zero-padded)
  1487.     %H    hour (24-hour clock) (00-23)
  1488.     %I    hour (12-hour clock) (01-12)
  1489.     %j    day of the year (001-366)
  1490.     %m    month (01-12)
  1491.     %M    minute (00-59)
  1492.     %p    AM or PM
  1493.     %S    second (00-59)
  1494.     %U    week number of the year (Sunday as 1st day of week) (00-52)
  1495.     %w    weekday (0-6, Sunday is 0)
  1496.     %W    week number of the year (Monday as 1st day of week) (00-52)
  1497.     %x    date
  1498.     %X    time
  1499.     %y    year without century (00-99)
  1500.     %Y    year with century
  1501.     %Z    time zone name, if any
  1502.     %%    % (percent symbol)
  1503.  
  1504. This function is the Baja equivalent of the standard C strftime() function.
  1505. Example:
  1506.  
  1507.     # Display current date and time
  1508.     INT T
  1509.     TIME T
  1510.     FTIME_STR STR "Current_Time:%A,%B-%d-%Y,%I:%M %p" T
  1511.     PRINTF "%s\r\n" STR
  1512.  
  1513. SHIFT_STR [str_var] <#>
  1514.      args: string    len
  1515. ------------------------
  1516. This function ("Shift String") shifts the specified string variable if
  1517. specified (current command string if not specified) to the left 'len' number of
  1518. characters.
  1519.  
  1520.     # Displays the string "ELLO"
  1521.     SETSTR "HELLO"
  1522.         SHIFT_STR 1
  1523.     PRINT STR
  1524.  
  1525. This function is most often used to parse command string arguments or "stacked"
  1526. commands.
  1527.  
  1528.  
  1529. _______________________________________________________________________________
  1530. Synchronet                           26           String Manipulation Functions
  1531.  
  1532.  
  1533. STRIP_CTRL [str_var]
  1534.       args: string
  1535. --------------------
  1536. Removes all control characters (and Ctrl-A codes) from specified string
  1537. variable. If string is not specified, then the current command string is
  1538. processed.
  1539.  
  1540. TRUNCSP [str_var]
  1541.    args: string
  1542. -----------------
  1543. Removes (truncates) all white space characters from end of specified string
  1544. variable or current comand string (if string not specified).
  1545.  
  1546. STRUPR [str_var]
  1547.   args: string
  1548. ----------------
  1549. Converts specified string argument to all uppercase characters. This function
  1550. is the Baja equivalent to the standard C strupr() function.
  1551.  
  1552. STRLWR [str_var]
  1553.   args: string
  1554. ----------------
  1555. Converts specified string argument to all lowercase characters. This function
  1556. is the Baja equivalent to the standard C strlwr() function.
  1557.  
  1558. SETSTR <"cstr">
  1559.   args: text
  1560. ---------------
  1561. Writes to current command string, specified constant text string. This
  1562. function should be used in place of "SET STR" for best optimization.
  1563.  
  1564. REPLACE_TEXT <#> <"cstr">
  1565.     args: num text
  1566. -------------------------
  1567. This function is used to replace a default internal text string (read from the
  1568. CTRL\TEXT.DAT file) in a shell or module. The first argument (num) is the text
  1569. number to replace (see TEXT.DAT for the number of the text you wish to
  1570. replace). The second argument (text) is the C type string to use in place the
  1571. current one. All text replacements are lost (back to default TEXT.DAT) when the
  1572. user logs off. Example, to replace the "[Hit a key]" prompt with a different
  1573. string:
  1574.  
  1575.         REPLACE_TEXT 563 "\1n\1h\1b{\1wPAUSE\1b} "
  1576.  
  1577. When replacing a TEXT.DAT string that contains %s, %d, or other % specifiers,
  1578. you will need to change them to %%s, %%d, etc (without changing the order).
  1579.  
  1580. If you wish to globally replace a string (for all shells and modules), you may
  1581. want to just edit the CTRL\TEXT.DAT file directly instead.
  1582.  
  1583.  
  1584.  
  1585.  
  1586.  
  1587.  
  1588. _______________________________________________________________________________
  1589. Synchronet                           27           String Manipulation Functions
  1590.  
  1591.  
  1592. LOAD_TEXT <"str">
  1593.      args: filename
  1594. -------------------
  1595. Loads an alternate TEXT.DAT file (from CTRL directory, automatically assuming
  1596. a .DAT extension for "filename"). Only those text items that are different
  1597. from the current TEXT items will be changed. All changes will only be in
  1598. effect until the current user logs off or the effects are reversed with the
  1599. REVERT_TEXT function. The base filename should be something other than just
  1600. "TEXT" (since that is the default TEXT.DAT that is loaded by SBBS).
  1601.  
  1602. This function is useful for making multiple languages available to your users.
  1603.  
  1604. REVERT_TEXT <# or ALL>
  1605.        args: num
  1606. ----------------------
  1607. This function is used to reverse the effects of a previous call to REPLACE_TEXT
  1608. or LOAD_TEXT (reverts back to default TEXT.DAT). Example:
  1609.  
  1610.         REPLACE_TEXT 563 "\1n-=[Hit a Key]=- "
  1611.         PAUSE
  1612.         REVERT_TEXT 563
  1613.  
  1614. If the argument is the word ALL, then all text strings are reverted to the
  1615. original TEXT.DAT entries.
  1616.  
  1617.  
  1618.  
  1619.  
  1620.  
  1621.  
  1622.  
  1623.  
  1624.  
  1625.  
  1626.  
  1627.  
  1628.  
  1629.  
  1630.  
  1631.  
  1632.  
  1633.  
  1634.  
  1635.  
  1636.  
  1637.  
  1638.  
  1639.  
  1640.  
  1641.  
  1642.  
  1643.  
  1644.  
  1645.  
  1646.  
  1647. _______________________________________________________________________________
  1648. Synchronet                           28           String Manipulation Functions
  1649.  
  1650.  
  1651. Integer Manipulation Functions
  1652. ==============================
  1653.  
  1654. Functions used for manipulating integer variables (global or local).
  1655.  
  1656.  INT <int_var> [int_var] [...]
  1657. args: new_vars
  1658. ------------------------------
  1659. Define one or more local integer variables for later use. The new_vars
  1660. arguments are the names of the variables to define. These names must not be
  1661. currently used by other variables (local or global).
  1662.  
  1663. After definition, the variable names can be used by other functions. The
  1664. variables will each be initialized to a 0. The variables can only be referenced
  1665. in the current shell or module. When the current shell or module is terminated,
  1666. the variable names and their contents are lost. If you wish to retain a
  1667. variable name and its contents between shells or modules, use a global variable
  1668. instead of a local variable.
  1669.  
  1670. GLOBAL_INT <int_var> [int_var] [...]
  1671.       args: new_vars
  1672. ------------------------------------
  1673. Define one or more global integer variables for later use. The arguments are
  1674. the names of the variables to define. Each variable name must not be currently
  1675. used by another variable (local or global). Global variable names and their
  1676. contents are not disposed of until the current user logs off the BBS.
  1677.  
  1678.  SET <int_var> <#>
  1679. args: dest      value
  1680. ---------------------
  1681. Writes to the integer variable dest, the integer constant specified as value.
  1682.  
  1683.     INT I
  1684.     SET I 100
  1685.  
  1686.  ADD <int_var> <any_var or #>
  1687. args: dest    value
  1688. -----------------------------
  1689. Adds the value specified in the second argument to the integer variable
  1690. specified as dest.
  1691.  
  1692.  SUB <int_var> <any_var or #>
  1693. args: dest    value
  1694. -----------------------------
  1695. Subtracts the value specified in the second argument from the integer variable
  1696. specified as dest.
  1697.  
  1698.  MUL <int_var> <any_var or #>
  1699. args: dest    value
  1700. -----------------------------
  1701. Multiplies the first argument by the value specified in the second argument
  1702. and places the result into dest.
  1703.  
  1704.  
  1705.  
  1706. _______________________________________________________________________________
  1707. Synchronet                           29          Integer Manipulation Functions
  1708.  
  1709.  
  1710.  DIV <int_var> <any_var or #>
  1711. args: dest    value
  1712. -----------------------------
  1713. Divides the first argument by the value specified in the second argument
  1714. and places the result into dest.
  1715.  
  1716.  MOD <int_var> <any_var or #>
  1717. args: dest    value
  1718. -----------------------------
  1719. Divides the first argument by the value specified in the second argument
  1720. and places the remainder into dest.
  1721.  
  1722.  AND <int_var> <any_var or #>
  1723. args: dest    value
  1724. -----------------------------
  1725. Bit-wise ANDs the value specified in the second argument with the integer
  1726. variable specified as dest.
  1727.  
  1728.  OR <int_var> <any_var or #>
  1729. args: dest    value
  1730. ----------------------------
  1731. Bit-wise ORs the value specified in the second argument with the integer
  1732. variable specified as dest.
  1733.  
  1734.  NOT <int_var> <any_var or #>
  1735. args: dest    value
  1736. -----------------------------
  1737. Bit-wise ANDs the unary opposite of the value specified in the second argument
  1738. with the integer variable specified as dest.
  1739.  
  1740.  XOR <int_var> <any_var or #>
  1741. args: dest    value
  1742. -----------------------------
  1743. Bit-wise exclusive ORs the value specified in the second argument with the
  1744. integer variable specified as dest.
  1745.  
  1746. COPY <int_var> <any_var>
  1747. args: dest      source
  1748. ------------------------
  1749. Copies the source variable (string or integer) into the specified destination
  1750. variable. Example:
  1751.  
  1752.     # define two variables
  1753.     INT INT1 INT2
  1754.     # place a value into the first variable
  1755.     SET VAR1 5
  1756.     # copy that variable into the second variable
  1757.     COPY VAR2 VAR1
  1758.     # display the contents of second variable
  1759.     PRINTF "VAR2=%ld\r\n" VAR2
  1760.  
  1761. If the source variable is an string variable, it is converted into an integer
  1762. before the copy is executed.
  1763.  
  1764.  
  1765. _______________________________________________________________________________
  1766. Synchronet                           30          Integer Manipulation Functions
  1767.  
  1768.  
  1769. SWAP <int_var> <any_var>
  1770. args: var1      var2
  1771. ------------------------
  1772. Exchanges the contents of two integer variables, or a string variable and an
  1773. integer variable. The first argument (var1) is the name of an integer variable
  1774. and the second argument (var2) is the name of a string or integer variable.
  1775.  
  1776. RANDOM <int_var> <#>
  1777.   args: dest      num
  1778. ---------------------
  1779. Places a random number between 0 and num-1 into dest.
  1780.  
  1781. TIME <int_var>
  1782. args: dest
  1783. --------------
  1784. Places the current time (in unix/time_t format) into dest. This function is
  1785. the Baja equivalent of the standard C time() function.
  1786.  
  1787. STRLEN <int_var> <str_var>
  1788.   args: dest      string
  1789. --------------------------
  1790. Places the length (in characters) of the specified string into dest. This
  1791. function is the Baja equivalent of the standard C strlen() function.
  1792.  
  1793. DATE_INT <int_var> <str_var>
  1794.     args: dest        date
  1795. ----------------------------
  1796. Converts a date string (in MM/DD/YY format) into an integer and places it
  1797. into dest.
  1798.  
  1799. CRC16 <int_var> <str_var>
  1800.  args: dest     string
  1801. -------------------------
  1802. Calculates the 16-bit CRC of the specified string and places the result into
  1803. dest.
  1804.  
  1805. CRC32 <int_var> <str_var>
  1806.  args: dest     string
  1807. -------------------------
  1808. Calculates the 32-bit CRC of the specified string and places the result into
  1809. dest.
  1810.  
  1811. CHKSUM <int_var> <str_var>
  1812.   args: dest      string
  1813. --------------------------
  1814. Calculates the CHKSUM of the specified string and places the result into
  1815. dest.
  1816.  
  1817. CHARVAL <int_var> <str_var>
  1818.    args: dest       string
  1819. ---------------------------
  1820. Places the ASCII value of the first character in the specified string into
  1821. dest.
  1822.  
  1823.  
  1824. _______________________________________________________________________________
  1825. Synchronet                           31          Integer Manipulation Functions
  1826.  
  1827.  
  1828. Logic/Control Flow Functions
  1829. ============================
  1830.  
  1831. GOTO <txt>
  1832. args: label
  1833. -----------
  1834. This function is used to force the control flow to immediately jump to another
  1835. part of the code. A valid label name must follow GOTO as an argument. This
  1836. function is very similar to the GOTO command used in the BASIC and C
  1837. programming languages or the JMP instruction used in the Assembly programming
  1838. language.
  1839.  
  1840. CALL <txt>
  1841. args: label
  1842. -----------
  1843. This function is used to execute a sub-routine. The sub-routine must be
  1844. defined with the specified label somewhere in the current module. When a
  1845. RETURN function is executed in the sub-routine, control flow will return to the
  1846. next line following the CALL function that started the sub-routine. The CALL
  1847. function is very similar to the GOSUB command used in the BASIC programming
  1848. langauge or the CALL instruction used in the Assembly programming language. At
  1849. least one RETURN function must exist in the sub-routine. Sub-routines should
  1850. not use a GOTO function to "jump out" of the sub-routine.
  1851.  
  1852. RETURN
  1853. ------
  1854. This function is used to exit a sub-routine and return to the point in the
  1855. code from which it was called with the CALL function. If a RETURN
  1856. function is executed without a prior CALL, then the shell or module is
  1857. immediately terminated. If a shell is terminated with a user online, they
  1858. are immediately logged off. If a module is terminated, execution control
  1859. returns to the shell or module that loaded it.
  1860.  
  1861. SETLOGIC <TRUE or FALSE or GREATER or LESS>
  1862.     args: logic
  1863. -------------------------------------------
  1864. This function is used to set the current logic state to TRUE (same as
  1865. EQUAL), FALSE (same as NOT_EQUAL), GREATER, or LESS. The logic state is set by
  1866. many functions, and tested by the IF_... functions to control the flow of
  1867. execution.
  1868.  
  1869. COMPARE <any_var> <any_var or "cstr" or #>
  1870.    args: var       cmp
  1871. ------------------------------------------
  1872. This function compares any two variables, or a variable and a constant.
  1873. If the cmp argument is an integer variable or integer constant and the
  1874. var variable is a string variable, then cmp is converted to a string
  1875. representation of the cmp variable before the comparison is made. If the cmp
  1876. argument is a string variable or string constant and the var variable is
  1877. an integer variable, then cmp is converted to an integer before the comparison
  1878. is made. The current logic state is set to the result of the comparion:
  1879. TRUE (same as EQUAL), FALSE (as an NOT_EQUAL), GREATER, or LESS.
  1880.  
  1881.  
  1882.  
  1883. _______________________________________________________________________________
  1884. Synchronet                           32            Logic/Control Flow Functions
  1885.  
  1886.  
  1887. IF_TRUE
  1888. -------
  1889. If the current logic state is set to TRUE, then following block of code
  1890. (ending in an END_IF or ELSE function) will be executed. Otherwise,
  1891. the interpreter will skip the code until an ELSE or END_IF function is found
  1892. and resume execution from that point. This function is the same as IF_EQUAL.
  1893.  
  1894. IF_FALSE
  1895. --------
  1896. This function is identical to the IF_TRUE function except that it works in the
  1897. opposite manor in regards to the current logic state. This function is the
  1898. same as IF_NOT_EQUAL.
  1899.  
  1900. IF_GREATER
  1901. ----------
  1902. If the current logic state is set to GREATER by a subsequent COMPARE function,
  1903. the following IF_... block will be executed.
  1904.  
  1905. IF_GREATER_OR_EQUAL
  1906. -------------------
  1907. If the current logic state is set to GREATER or EQUAL, the following IF_...
  1908. block will be executed. This function is the same as IF_EQUAL_OR_GREATER.
  1909.  
  1910. IF_LESS
  1911. -------
  1912. If the current logic state is set to LESS by a subsequent COMPARE function,
  1913. the following block will be executed.
  1914.  
  1915. IF_LESS_OR_EQUAL
  1916. ----------------
  1917. If the current logic state is set to LESS or EQUAL, the following code block
  1918. will be executed. This function is the same as IF_EQUAL_OR_LESS.
  1919.  
  1920. ELSE
  1921. ----
  1922. This function marks the end of an IF_... block of code and begins an alternate
  1923. block of code to be executed if the condition is not met for the IF_...
  1924. function. The block of code is terminated with an END_IF function.
  1925.  
  1926. END_IF
  1927. ------
  1928. This function is used to terminate an IF_... or  ELSE code block. Every IF_...
  1929. function must be followed by an ELSE or END_IF instuction, and every ELSE
  1930. function must be followed by an END_IF.
  1931.  
  1932.  
  1933.  
  1934.  
  1935.  
  1936.  
  1937.  
  1938.  
  1939.  
  1940.  
  1941.  
  1942. _______________________________________________________________________________
  1943. Synchronet                           33            Logic/Control Flow Functions
  1944.  
  1945.  
  1946. SWITCH <int_var>
  1947. ----------------
  1948. CASE <#>
  1949. --------
  1950. END_CASE
  1951. --------
  1952. DEFAULT
  1953. -------
  1954. END_SWITCH
  1955. ----------
  1956. The SWITCH function is used in conjunction with the CASE, DEFAULT, END_CASE,
  1957. and END_SWITCH functions to replace multiple COMPARE/IF_.../ELSE statements.
  1958.  
  1959. Example:
  1960.  
  1961.     INT I
  1962.     RANDOM I 3
  1963.     COMPARE I 0
  1964.     IF_EQUAL
  1965.         PRINT "Zero"
  1966.     ELSE
  1967.         COMPARE I 1
  1968.         IF_EQUAL
  1969.             PRINT "One"
  1970.         ELSE
  1971.             COMPARE I 2
  1972.             IF_EQUAL
  1973.                 PRINT "Two"
  1974.                 END_IF
  1975.             END_IF
  1976.         END_IF
  1977.  
  1978. Could be replaced with:
  1979.  
  1980.     INT I
  1981.     RANDOM I 3
  1982.     SWITCH I
  1983.         CASE 0
  1984.             PRINT "Zero"
  1985.             END_CASE
  1986.         CASE 1
  1987.             PRINT "One"
  1988.             END_CASE
  1989.         CASE 2
  1990.             PRINT "Two"
  1991.             END_CASE
  1992.         DEFAULT
  1993.             PRINTF "Random returned %ld" I
  1994.             END_CASE
  1995.         END_SWITCH
  1996.  
  1997.  
  1998.  
  1999.  
  2000.  
  2001. _______________________________________________________________________________
  2002. Synchronet                           34            Logic/Control Flow Functions
  2003.  
  2004.  
  2005. If the SWITCH argument value is equal to one of the specified CASE arguments,
  2006. then that CASE code block is executed until an END_CASE function is reached.
  2007. If an END_CASE function does not exist in the code block, the execution will
  2008. continue through (fall-through) the following CASE or DEFAULT functions until
  2009. an END_CASE or END_SWITCH function is reached.
  2010.  
  2011. If the SWITCH argument does not match any of the CASE arguments, the DEFAULT
  2012. code block will be executed until an END_CASE or END_SWITCH function is
  2013. reached. If a DEFAULT function is not specified, execution will skip to the
  2014. END_SWITCH function. Only one DEFAULT code block should be specified per
  2015. SWITCH/END_SWITCH block, if used at all. This function set is the Baja
  2016. equivalent of the standard C switch(), case:, default:, and break keywords.
  2017.  
  2018. CMD_HOME
  2019. --------
  2020. This function (called "Command Home") is very similar to a label. It is
  2021. a convenience function for programming menu commands. It sets a return
  2022. point (or anchor, if you will) for the automatic looping on a specific menu.
  2023. Execution control is returned to the point in the code where the last CMD_HOME
  2024. was specified by the END_CMD function.
  2025.  
  2026. CMDKEY <key>
  2027.  args:    cmd
  2028. ------------
  2029. This function (called "Command Key") is like a combination of the
  2030. COMPARE_KEY and IF_TRUE functions. It is usually immediately preceded by
  2031. a GETCMD, GETKEY, GETSTR or similar function.
  2032.  
  2033. If the current command key matches the command key constant (cmd), then the
  2034. block of code following (terminated with an END_CMD function) will be executed.
  2035. When the END_CMD function is executed, execution control returns to the most
  2036. recently executed CMD_HOME function. If a RETURN or GOTO function will be
  2037. executed before the END_CMD function, then a CMD_POP function must be executed
  2038. to tell the interpreter to "forget" the previous CMD_HOME function. Even if
  2039. execution control will cause the END_CMD function to never be executed, it
  2040. still must be present to define the code block so that it can be skipped if the
  2041. CMDKEY comparison is false.
  2042.  
  2043.  
  2044.  
  2045.  
  2046.  
  2047.  
  2048.  
  2049.  
  2050.  
  2051.  
  2052.  
  2053.  
  2054.  
  2055.  
  2056.  
  2057.  
  2058.  
  2059.  
  2060. _______________________________________________________________________________
  2061. Synchronet                           35            Logic/Control Flow Functions
  2062.  
  2063.  
  2064. CMDKEYS <keylist>
  2065.   args:  cmds
  2066. -----------------
  2067. This function is identical to the CMDKEY function with the exception that the
  2068. argument is a list of valid keys and if the current command key matches any
  2069. of those listed, the following code block is executed.
  2070.  
  2071. CMDSTR <"cstr">
  2072.   args: cmd
  2073. ---------------
  2074. This function (called "Command Str") is identical to the CMDKEY function
  2075. with the exception that the argument is a C type string. It is usually
  2076. immediately preceded by a GETSTR or similar function.
  2077.  
  2078. END_CMD
  2079. -------
  2080. This function is used to mark the end of a CMDKEY, CMDKEYS, or CMDSTR code
  2081. block.
  2082.  
  2083. CMD_POP
  2084. -------
  2085. This function tells the interpreter to "forget" the most recently executed
  2086. CMD_HOME function. It should only be used when a CMDKEY, CMDKEYS, or CMDSTR
  2087. code block contains a GOTO or RETURN function.
  2088.  
  2089. COMPARE_KEY <key>
  2090.        args: cmd
  2091. -----------------
  2092. This function is identcal to the CMDKEY function in regards to the
  2093. key argument. The current command key is set by the GETCMD, GETKEY, GETSTR
  2094. or similar functions. If the current command key matches the key argument,
  2095. the current logic state is set to TRUE, otherwise it is set to FALSE.
  2096.  
  2097. As with all COMPARE functions, it is usually immediately followed by an
  2098. IF_TRUE or IF_FALSE function.
  2099.  
  2100. COMPARE_KEYS <keylist>
  2101.     args: cmds
  2102. ----------------------
  2103. This function is identical to the CMDKEYS functions in regards to the
  2104. keylist argument. If the current command key is contained in the keylist,
  2105. then the current logic state is set to TRUE, otherwise it is set to FALSE.
  2106.  
  2107. COMPARE_STR <"cstr">
  2108.        args: string
  2109. --------------------
  2110. This function compares the current command string (set by the SETSTR,
  2111. GETSTR, or similar functions) against the C type string argument and sets
  2112. the current logic state to TRUE or FALSE accordingly. The comparison is not
  2113. case sensitive. This function is the Baja equivalent to the standard C
  2114. stricmp() function.
  2115.  
  2116.  
  2117.  
  2118.  
  2119. _______________________________________________________________________________
  2120. Synchronet                           36            Logic/Control Flow Functions
  2121.  
  2122.  
  2123. COMPARE_WORD <"cstr">
  2124.     args: string
  2125. ---------------------
  2126. This function is identical to the COMPARE_STR function with the
  2127. exception that the current command string must only match the string argument
  2128. for as many characters as included in the string argument.
  2129.  
  2130. If for example, the current command string is "OPEN BLACKJACK" then the line:
  2131.  
  2132.         COMPARE_WORD "OPEN"
  2133.  
  2134. would set the current logic state to TRUE since the first 4 characters of
  2135. each string match, but the line:
  2136.  
  2137.         COMPARE_STR "OPEN"
  2138.  
  2139. would set the current logic state to FALSE since the strings do not entirely
  2140. match.
  2141.  
  2142. COMPARE_ARS <txt>
  2143.        args: ars
  2144. -----------------
  2145. This function compares the requirement string argument ars against the
  2146. information on the current user and sets the current logic state to either
  2147. TRUE or FALSE based on the result of the comparison. See the ARS chapter of
  2148. the Synchronet sysop manual for details on the syntax of ARS.
  2149.  
  2150. Example:
  2151.                 COMPARE_ARS LEVEL 60
  2152.                 IF_TRUE
  2153.                         PRINT "You have level 60 or higher.\r\n"
  2154.                         END_IF
  2155.  
  2156. COMPARE_STRN <#>  <str_var> <str_var or "cstr">
  2157.     args: num  str1      str2
  2158. -----------------------------------------------
  2159. This function is used to compare the first num characters of strings str1
  2160. and str2. This function is the Baja equivalent of the standard C strnicmp()
  2161. function. If the two strings are the same (ignoring case) for the the first
  2162. num characters, the current logic state is set to TRUE, otherwise it is set
  2163. to FALSE.
  2164.  
  2165. COMPARE_SUBSTR <str_var> <str_var or "cstr">
  2166.       args: str1      str2
  2167. --------------------------------------------
  2168. This function is used to check if str2 is contained in str1 (case sensitive).
  2169. This function is the Baja equivalent of the standard C strstr() function.
  2170. If str2 is located in str1, the current logic state is set to TRUE, otherwise
  2171. it is set to FALSE. This following example would set the current logic state
  2172. to TRUE:
  2173.  
  2174.     SETSTR "This is a test"
  2175.     COMPARE_SUBSTR STR "test"
  2176.  
  2177.  
  2178. _______________________________________________________________________________
  2179. Synchronet                           37            Logic/Control Flow Functions
  2180.  
  2181.  
  2182. Display Functions
  2183. =================
  2184.  
  2185. Display functions are used to display output to the user either locally,
  2186. remotely, or both.
  2187.  
  2188. PRINT <"cstr" or var>
  2189. args:  string
  2190. ---------------------
  2191. This function sends a string of characters to the user (both locally and
  2192. remotely, if applicable). The string to be printed can extend beyond the 80th
  2193. column of the screen, but when printing multiple lines, multiple consecutive
  2194. PRINT statements are preferrred.
  2195.  
  2196. Example:
  2197.                 PRINT "hello, world\r\n"
  2198.      or:
  2199.                 STR my_var
  2200.                 SET my_var "hello, world\r\n"
  2201.                 PRINT my_var
  2202.  
  2203. The string can contain color codes using Synchronet Ctrl-A codes. See the
  2204. Synchronet sysop manual for the definition of Ctrl-A codes and their usage.
  2205. If you are using an ASCII editor that does not support control characters,
  2206. a "\1" can be used in place of the Ctrl-A (smiley face) character.
  2207.  
  2208. Variables can also be included in the string (example: user's name, sysop's
  2209. name, BBS name, etc) by using Synchronet supported @-codes and command line
  2210. % specifiers. See the Synchronet sysop manual for the definition of @-codes
  2211. and command line % specifiers. The %s command line specifier, when used, is
  2212. replaced with the current command string and %f is replaced with the complete
  2213. path of the current file directory. Be careful not to confuse command line %
  2214. specifiers (%a, %b, etc) with printf % specifiers (described later). They can
  2215. actually be used together in the same string (supported by PRINTF functions) by
  2216. using double % for the command line % specifiers (e.g. %%s instead of %s).
  2217.  
  2218.  
  2219.  
  2220.  
  2221.  
  2222.  
  2223.  
  2224.  
  2225.  
  2226.  
  2227.  
  2228.  
  2229.  
  2230.  
  2231.  
  2232.  
  2233.  
  2234.  
  2235.  
  2236.  
  2237. _______________________________________________________________________________
  2238. Synchronet                           38                       Display Functions
  2239.  
  2240.  
  2241. PRINTF <"cstr"> [any_var] [...]
  2242.  args:    format     variables
  2243. -------------------------------
  2244. This function is similar to print, except that defined variables can be placed
  2245. (formatted) into to displayed text output. This function is the Baja
  2246. equivalent of the standard C printf() function. The format argument is a C type
  2247. string with C printf() % specifiers for variable formatting.
  2248.  
  2249. The valid specifiers are:
  2250.  
  2251.         %%      Percent symbol
  2252.         %s      String variable
  2253.         %#s     String variable, minimum # chars wide, right justified
  2254.         %-#s    String variable, minimum # chars wide, left justified
  2255.         %.#s    String variable, maximum # chars wide
  2256.         %#.#s   String variable, min and max width specified, right justified
  2257.         %-#.#s  String variable, min and max width specified, left justified
  2258.         %ld     Integer variable, decimal - use lx for hexadecimal (lX=caps)
  2259.         %#ld    Integer variable minimum # chars wide right justified
  2260.         %-#ld   Integer variable minimum # chars wide left justified
  2261.         %0#ld   Integer variable minimum # digits wide zero padded
  2262.  
  2263. Multiple variable names may be specified after the str argument, but each
  2264. variable MUST be properly represented in the str argument with the correct
  2265. PRINTF specifier (either %ld, %lx, or %s).
  2266.  
  2267. Example:
  2268.         STR s
  2269.         SET s "hello, world"
  2270.         PRINTF "~%s~\r\n"       s
  2271.         PRINTF "~%10s~\r\n"     s
  2272.         PRINTF "~%.10s~\r\n"    s
  2273.         PRINTF "~%-10s~\r\n"    s
  2274.         PRINTF "~%.15s~\r\n"    s
  2275.         PRINTF "~%-15s~\r\n"    s
  2276.         PRINTF "~%15.10s~\r\n"  s
  2277.         PRINTF "~%-15.10s~\r\n" s
  2278.  
  2279. Would produce the following display:
  2280.  
  2281.         ~hello, world~
  2282.         ~hello, world~
  2283.         ~hello, wor~
  2284.         ~hello, world~
  2285.         ~hello, world   ~
  2286.         ~     hello, wor~
  2287.         ~hello, wor     ~
  2288.  
  2289.  
  2290.  
  2291.  
  2292.  
  2293.  
  2294.  
  2295.  
  2296. _______________________________________________________________________________
  2297. Synchronet                           39                       Display Functions
  2298.  
  2299.  
  2300. And:
  2301.         INT i
  2302.         SET i 1234
  2303.     PRINTF "~%ld~\r\n"      i
  2304.     PRINTF "~%3ld~\r\n"     i
  2305.     PRINTF "~%6ld~\r\n"     i
  2306.     PRINTF "~%-6ld~\r\n     i
  2307.     PRINTF "~%06ld~\r\n"    i
  2308.     PRINTF "~%06lx~\r\n"    i
  2309.     PRINTF "~%06lX~\r\n"    i
  2310.  
  2311. Would produce the following display:
  2312.  
  2313.         ~1234~
  2314.         ~1234~
  2315.         ~  1234~
  2316.         ~1234  ~
  2317.         ~001234~
  2318.         ~0004d2~
  2319.         ~0004D2~
  2320.  
  2321. PRINT_LOCAL <"cstr">
  2322.        args:  string
  2323. --------------------
  2324. This function works identical to the PRINT function with the exception that
  2325. the output is only displayed locally (on the BBS console). Ctrl-A codes
  2326. and @-codes are not supported.
  2327.  
  2328. PRINT_REMOTE <"cstr">
  2329.     args: string
  2330. ---------------------
  2331. This function works identical to the PRINT function with the exception that
  2332. the output is only displayed remotely (on the user's terminal). If the current
  2333. user is not logged on remotely, then no output is performed. Ctrl-A codes
  2334. and @-codes are not supported.
  2335.  
  2336. PRINTSTR
  2337. --------
  2338. This function works identical to the PRINT function with the exception that
  2339. this function does not accept a string argument, and instead uses the current
  2340. command string (set with SETSTR, GETSTR, or similar function) as the character
  2341. string to print.
  2342.  
  2343. Example:
  2344.                 SETSTR "hello, world\r\n"
  2345.                 PRINTSTR
  2346.  
  2347. PRINTKEY
  2348. --------
  2349. This function displays the current command key. The command key is normally
  2350. obtained with the GETKEY, GETCMD, or similar function.
  2351.  
  2352.  
  2353.  
  2354.  
  2355. _______________________________________________________________________________
  2356. Synchronet                           40                       Display Functions
  2357.  
  2358.  
  2359. MNEMONICS <"cstr">
  2360.      args: string
  2361. ------------------
  2362. This function works identical to the PRINT function with the exception that
  2363. the output is automatically colorized and characters following a tilde (~)
  2364. are considered a mnemonic command character (hot key) and are high-lighted
  2365. or placed in parentheses if the user's terminal does not support ANSI. If
  2366. Ctrl-A codes are included in the str argument, then the automatic colorization
  2367. and high-lighting is not used.
  2368.  
  2369. Example:
  2370.                 mnemonics "Select: ~Good, ~Bad, or ~Indifferent: "
  2371.  
  2372. CLS
  2373. ---
  2374. This function clears the current text screen.
  2375.  
  2376. CRLF
  2377. ----
  2378. This function displays a carriage return/line feed (new line). It is equivalent
  2379. to PRINT "\r\n", but requires less memory and executes faster.
  2380.  
  2381. PRINTFILE <"str" or str_var> [#]                                SBBSDEFS.INC
  2382.      args: file           mode
  2383. ----------------------------------
  2384. Displays the contents of the file to the user (both locally and remotely, if
  2385. applicable).
  2386.  
  2387. Valid mode parameters:
  2388.  
  2389. P_NOABORT    Disallows abortion of display with Ctrl-C
  2390. P_SAVEATR    Retain attributes (colors) after display
  2391. P_NOATCODES    Don't expand @-code variables/actions
  2392. P_OPENCLOSE    Open and close immediately (before display)
  2393.  
  2394. Multiple mode parameters can be specified by joining them together with the
  2395. OR (|) symbol.
  2396.  
  2397. Example:
  2398.         !INCLUDE SBBSDEFS.INC
  2399.         PRINTFILE "C:\TEXT\HELP.TXT" P_NOABORT|P_OPENCLOSE
  2400.  
  2401. PRINTTAIL <str_var> <#>   <#>                    SBBSDEFS.INC
  2402.      args: file      mode  x
  2403. -----------------------------
  2404. Displays the last x number of lines of file. The valid mode parameters are the
  2405. same as those shown for the PRINTFILE function. If you don't want any of the
  2406. mode values, use 0 for the mode.
  2407.  
  2408. PRINTFILE_STR
  2409. -------------
  2410. This function is indentical to the PRINTFILE function, with the exception that
  2411. there is no argument, the current command string is used for the path and
  2412. filename instead.
  2413.  
  2414. _______________________________________________________________________________
  2415. Synchronet                           41                       Display Functions
  2416.  
  2417.  
  2418.  
  2419. PRINTFILE_LOCAL <"str">
  2420.        args: file
  2421. -----------------------
  2422. This function works identical to the PRINTFILE function, with the exception
  2423. that the contents are only displayed locally.
  2424.  
  2425. PRINTFILE_REMOTE <"str">
  2426.         args: file
  2427. ----------------------
  2428. This function works identical to the PRINTFILE function, with the exception
  2429. that the contents are only displayed remotely. If the user is not logged on
  2430. remotely, then no output is performed.
  2431.  
  2432. LIST_TEXT_FILE
  2433. --------------
  2434. This function works similar to the PRINTFILE function, with the exception
  2435. that the system password is required when run remotely and the user is prompted
  2436. to enter the path and name of the file to list.
  2437.  
  2438. EDIT_TEXT_FILE
  2439. --------------
  2440. This function is generally for sysop use only. It will automatically prompt
  2441. the user (if remote) for the system password, and then prompt them for the
  2442. path and name of the file to edit.
  2443.  
  2444. PAUSE
  2445. -----
  2446. This function produces a "[Hit a key]" prompt and waits for the user to hit a
  2447. key.
  2448.  
  2449. MENU <"str">
  2450. args: file
  2451. ----------
  2452. This function is similar to the PRINTFILE function with the exception that the
  2453. TEXT\MENU directory is assumed to be the root path for the file and the file's
  2454. extension (.ASC, .ANS, .MON, or .RIP) should not be specified. This function
  2455. will automatically display the correct file based on the what the user's
  2456. terminal supports and which menu files are available. To display a menu file
  2457. in a different directory, a sub-directory can be specified before the filename.
  2458. For example, do display the MAIN.* menu file in the TEXT\MENU\SIMPLE directory,
  2459. you would use the following:
  2460.  
  2461.     MENU "SIMPLE\MAIN"
  2462.  
  2463. To display the MAIN.* menu file in the TEXT\MENU directory, you would use the
  2464. following:
  2465.  
  2466.     MENU "MAIN"
  2467.  
  2468. You can also change the default menu directory with the SET_MENU_DIR function.
  2469. Using the SET_MENU_FILE function, you can override the location and filename
  2470. for MENUs that are displayed from within core functions of Synchronet.
  2471.  
  2472.  
  2473. _______________________________________________________________________________
  2474. Synchronet                           42                       Display Functions
  2475.  
  2476.  
  2477. NODELIST_ALL
  2478. ------------
  2479. This function displays the current status of all nodes.
  2480.  
  2481. NODELIST_USERS
  2482. --------------
  2483. This function displays the current status of all nodes that are in use.
  2484.  
  2485. USERLIST_SUB
  2486. ------------
  2487. This function displays all users that have access to the current message
  2488. sub-board.
  2489.  
  2490. USERLIST_DIR
  2491. ------------
  2492. This function displays all users that have access to the current file
  2493. directory.
  2494.  
  2495. USERLIST_ALL
  2496. ------------
  2497. This function displays all users that have active accounts on the BBS.
  2498.  
  2499. USERLIST_LOGONS
  2500. ---------------
  2501. This function displays a list of the users who have logged on today.
  2502.  
  2503. YES_NO <"cstr">
  2504.   args: question
  2505. ----------------
  2506. This function displays the question argument with automatic colorization
  2507. followed by the text " (Y/n) ? " and waits for the user to hit 'Y', 'N' or CR.
  2508. If CR (enter) is hit, then 'Y' is assumed. If the answer to the prompt is 'Y',
  2509. then the current logic state is set to TRUE, otherwise it is set to FALSE.
  2510.  
  2511. Example:
  2512.                 YES_NO "Logoff Now"
  2513.                 IF_TRUE
  2514.                         LOGOFF
  2515.                         END_IF
  2516.  
  2517. NO_YES <"cstr">
  2518.   args: question
  2519. ----------------
  2520. This function is identical to the YES_NO function with the exception that the
  2521. string is followed by text " (y/N) ? " and if CR is hit, then 'N' is assumed.
  2522. If the answer to the prompt is 'N', then the current logic state is set to
  2523. TRUE, otherwise it is set to FALSE.
  2524.  
  2525. Example:
  2526.                 NO_YES "Logoff Now"
  2527.                 IF_FALSE
  2528.                         LOGOFF
  2529.                         END_IF
  2530.  
  2531.  
  2532. _______________________________________________________________________________
  2533. Synchronet                           43                       Display Functions
  2534.  
  2535.  
  2536. READ_SIF <"str">
  2537.     args: file
  2538. --------------
  2539. This function displays the contents of a SIF questionnaire data file (path and
  2540. filename specified in the current command command string). The data is read
  2541. from the SIF data file and displayed through the SIF questionnaire file:
  2542. "TEXT\file.SIF".
  2543.  
  2544. The original SIF data file is created with the CREATE_SIF function. The
  2545. SIF file used to create and display the data file do not have to be the same
  2546. SIF file, but should have the same order and format of data types.
  2547.  
  2548. See the Synchronet Sysop Manual for details on the SIF file format.
  2549.  
  2550. SAVELINE
  2551. --------
  2552. This function saves the current line of text on the console to an internal
  2553. Synchronet buffer for later re-display with the RESTORELINE function.
  2554.  
  2555. RESTORELINE
  2556. -----------
  2557. This function re-displays a previously saved line of text to the local and
  2558. remote console (if applicable).
  2559.  
  2560.  
  2561.  
  2562.  
  2563.  
  2564.  
  2565.  
  2566.  
  2567.  
  2568.  
  2569.  
  2570.  
  2571.  
  2572.  
  2573.  
  2574.  
  2575.  
  2576.  
  2577.  
  2578.  
  2579.  
  2580.  
  2581.  
  2582.  
  2583.  
  2584.  
  2585.  
  2586.  
  2587.  
  2588.  
  2589.  
  2590.  
  2591. _______________________________________________________________________________
  2592. Synchronet                           44                       Display Functions
  2593.  
  2594.  
  2595. Input Functions
  2596. ===============
  2597.  
  2598. Input functions are used to obtain input data from the user (most often from
  2599. the user's keyboard).
  2600.  
  2601. INKEY
  2602. -----
  2603. Checks to see if the user has hit a key. If the user has hit a key, the
  2604. current command key is set to the hit key and the current logic state is
  2605. set to TRUE, otherwise the logic state is set to FALSE. This function does
  2606. not wait for a user to hit a key.
  2607.  
  2608. GETKEY
  2609. ------
  2610. Waits for a single key from the user. The key is converted to upper case (if
  2611. a letter) and becomes the current command key for functions such as CMDKEY,
  2612. COMPARE_KEY, etc. The key is not echoed (displayed). Use the PRINTKEY function
  2613. to display a key accepted with this function.
  2614.  
  2615. GETKEYE
  2616. -------
  2617. This function is identical to the GETKEY function with the exception that
  2618. "slash commands" are allowed. That is, if the user hits the slash (/) key,
  2619. then the slash is echoed and the system waits for another key from the user.
  2620. The second key is converted to upper case (if a letter) and the slash/key
  2621. combination becomes the current command key for functions such as CMDKEY,
  2622. COMPARE_KEY, etc. The second key is not echoed (displayed). Use the PRINTKEY
  2623. function to display a key accepted with this function.
  2624.  
  2625. GETCMD <"cstr">
  2626.   args: keys
  2627. ---------------
  2628. This function is very similar to the GETKEY function, except that the 'keys'
  2629. argument specifies the only valid key to be accepted. The keys arguments is
  2630. a C style string, so carriage return (ENTER) is specified with a \r. If, for
  2631. example, you wanted to allow the user to hit A, B, C or ENTER, then you would
  2632. use the following:
  2633.  
  2634.         GETCMD "ABC\r"
  2635.  
  2636. When an allowed key is hit, the key is converted to upper case (if a letter)
  2637. and echoed (displayed) followed by a CRLF automatically. The key then becomes
  2638. the current command key for functions such as CMDKEY, COMPARE_KEY, etc.
  2639.  
  2640. Ctrl-C will always be allowed, in which case the command key becomes ^C.
  2641.  
  2642.  
  2643.  
  2644.  
  2645.  
  2646.  
  2647.  
  2648.  
  2649.  
  2650. _______________________________________________________________________________
  2651. Synchronet                           45                         Input Functions
  2652.  
  2653.  
  2654. GETSTR [str_var] [#]  [#]                    SBBSDEFS.INC
  2655.   args: string      max  mode
  2656. ---------------------------
  2657. This function ("Get String"), is used to accept a string of characters from
  2658. the user. The 'max' argument specifies the maximum length allowed for the
  2659. string (in characters). 'max' should not exceed 79 characters for most uses.
  2660. This function allows the user to enter any valid ASCII characters to form
  2661. command words, sentences, etc. Control will not return to the module until the
  2662. user either hits CR (ENTER), Ctrl-C, or Ctrl-V or is disconnected. The
  2663. resultant string can then be used in functions such as CMDSTR, COMPARE_STR,
  2664. COMPARE, SHIFT_STR, XTRN_EXEC, FILE_DOWNLOAD, etc.
  2665.  
  2666. If string is not specified, the current command string is written to. If
  2667. max is not specified, the value 128 is used.
  2668.  
  2669. The valid mode parameters (defined in SBBSDEFS.INC) are:
  2670.  
  2671. Mode        Description
  2672. ~~~~        ~~~~~~~~~~~
  2673. K_UPPER     Converts all letters to upper case
  2674. K_UPRLWR    Upper/Lower case automatically
  2675. K_NUMBER    Allow numbers only
  2676. K_WRAP        Allows word wrap
  2677. K_MSG        Allows Ctrl-A codes and Ctrl-G (beep)
  2678. K_SPIN        Spinning cursor
  2679. K_LINE        Input line (inverse color)
  2680. K_EDIT        Edit string passed
  2681. K_NOCRLF    Don't print CRLF after string input
  2682. K_ALPHA     Only allow alphabetic characters
  2683. K_LOWPRIO    low priority input
  2684. K_NOEXASC    No extended ASCII allowed
  2685. K_E71DETECT    Detect E-7-1 terminal type
  2686. K_AUTODEL    Auto-delete text (used with EDIT)
  2687. K_NOECHO    Don't echo input to local or remote console
  2688.  
  2689. Multiple mode parameters can be used by ORing them together with the | symbol.
  2690. Example:
  2691.  
  2692.     GETSTR STR 25 K_UPRLWR|K_EDIT|K_AUTODEL
  2693.  
  2694. GETLINE [str_var] [#]
  2695.    args: string    max
  2696. --------------------------
  2697. This function is identical to GETSTR with the exception that an inverse line
  2698. is displayed to the user (if the user has an ANSI terminal) to show the maximum
  2699. length of the input string.
  2700.  
  2701. GETSTRUPR [str_var] [#]
  2702.      args: string    max
  2703. ------------------------
  2704. This function ("Get String Upper") is identical to GETSTR with the exception
  2705. that the string is automatically converted to uppercase as the user types.
  2706.  
  2707.  
  2708.  
  2709. _______________________________________________________________________________
  2710. Synchronet                           46                         Input Functions
  2711.  
  2712.  
  2713. GETNAME [str_var] [#]
  2714.    args: string    max
  2715. ----------------------
  2716. This function is identical to GETSTR with the exception that the string is
  2717. automatically converted to "Capitalized" words (as in a proper noun) as the
  2718. user types.
  2719.  
  2720. GETFILESPEC
  2721. -----------
  2722. This function is specifically used to accept a file specification (name and/or
  2723. wildcard characters) from the user. It will automatically display a prompt
  2724. similar to:
  2725.  
  2726. Filespec [*.*]:
  2727.  
  2728. before waiting for the user to input the file specification. If the user hits
  2729. CR, *.* is assumed to be the file specification. If a period is not included
  2730. in the string, a ".*" is automatically appended (so CR, "*" and "*.*" all
  2731. result in the same string: "*.*"). If the user enters "A*", the string becomes
  2732. "A*.*". If the user enters "A*." the string remains unchanged. If the user
  2733. hits Ctrl-C, the current logic state is set to FALSE. Otherwise, the logic
  2734. state is set to TRUE.
  2735.  
  2736. Example:
  2737.  
  2738.         GETFILESPEC
  2739.         IF_TRUE
  2740.                 FILE_DOWNLOAD
  2741.                 END_IF
  2742.  
  2743. GETLINES
  2744. --------
  2745. This function only has an effect if the user is logged on remotely, has
  2746. ANSI terminal capability and their screen lines set to "Auto-detect". It
  2747. sends an ANSI sequence to detect the number of screen lines in the text window
  2748. of the remote terminal and waits for a response.
  2749.  
  2750. GETNUM [any_var] <#>
  2751.   args: dest      max
  2752. ---------------------
  2753. This function is similar to GETSTR with the exception that it only excepts
  2754. numbers as input and automatically stops accepting input if the number being
  2755. input would exceed max (maximum of 32767). The dest variable (current
  2756. command string if not specified) will contain the number and the current logic
  2757. state will be TRUE unless the user hit 'Q', Ctrl-C, or enter instead of a
  2758. number.
  2759.  
  2760.  
  2761.  
  2762.  
  2763.  
  2764.  
  2765.  
  2766.  
  2767.  
  2768. _______________________________________________________________________________
  2769. Synchronet                           47                         Input Functions
  2770.  
  2771.  
  2772. GET_TEMPLATE <"str">
  2773. ------------------
  2774. This function is much line GETLINE except that an input template is passed
  2775. as an argument to this function. The template is useful when requiring the
  2776. user to input a string of a fixed format, like a date, for example. The
  2777. characters in the template have special meaning: N indicates only a number may
  2778. be used in this position, A indicates only an alphabetic character, and !
  2779. indicates any character may be used in that position. Characters other than
  2780. N, A, or ! are automatically displayed and used in the current command string
  2781. in those positions. The first character of the template must be either N, A, or
  2782. !. An example (date format):
  2783.  
  2784.     GET_TEMPLATE "NN/NN/NN"
  2785.  
  2786. would require the user to input two numbers, then automatically skip the
  2787. slash character, two more numbers, skip the slash, then two more numbers.
  2788.  
  2789. Another example (Canadian postal code):
  2790.  
  2791.     GET_TEMPLATE "ANA NAN"
  2792.  
  2793. would require the user to input a letter, then a number, another letter,
  2794. automatically skip the space, another number, another letter, and one more
  2795. number. No other characters (symbols or otherwise) would be allowed in the
  2796. string using the above template example.
  2797.  
  2798. CHKSYSPASS
  2799. ----------
  2800. This function ("Check System Password") displays an SY: prompt to the user
  2801. and waits for the user to input the system password (with no echo). If the
  2802. password is correct, the current logic state is set to TRUE, otherwise it
  2803. is set to FALSE.
  2804.  
  2805.  
  2806.  
  2807.  
  2808.  
  2809.  
  2810.  
  2811.  
  2812.  
  2813.  
  2814.  
  2815.  
  2816.  
  2817.  
  2818.  
  2819.  
  2820.  
  2821.  
  2822.  
  2823.  
  2824.  
  2825.  
  2826.  
  2827. _______________________________________________________________________________
  2828. Synchronet                           48                         Input Functions
  2829.  
  2830.  
  2831. CREATE_SIF <"str">
  2832.       args: file
  2833. ----------------
  2834. This function is used to present the user with a SIF questionnaire and store
  2835. their answers in a data file. The str argument is the filename of a .SIF file
  2836. (without the .SIF extension) located in your Synchronet TEXT directory. The
  2837. user's answers are stored in a data file whose path and filename are specified
  2838. in the current command string. The data file should be specified with the
  2839. user's number to ensure unique data filenames. Example:
  2840.  
  2841.     SETSTR "C:\\SBBS\\USER%4.DAT"
  2842.     CREATE_SIF "NEWUSER"
  2843.  
  2844. This would read the file TEXT\NEWUSER.SIF and the user would fill-out the
  2845. questionnaire with all answers being stored in the file C:\SBBS\USER####.DAT
  2846. (where #### would be the user's number padded with zeros to four digits).
  2847. The questionnaire could then be read back with the answers filled in.
  2848. Example:
  2849.  
  2850.     SETSTR "C:\\SBBS\\USER%4.DAT"
  2851.     READ_SIF "NEWUSER"
  2852.  
  2853. See the Synchronet Sysop Manual for details on the SIF questionnaire format.
  2854.  
  2855.  
  2856.  
  2857.  
  2858.  
  2859.  
  2860.  
  2861.  
  2862.  
  2863.  
  2864.  
  2865.  
  2866.  
  2867.  
  2868.  
  2869.  
  2870.  
  2871.  
  2872.  
  2873.  
  2874.  
  2875.  
  2876.  
  2877.  
  2878.  
  2879.  
  2880.  
  2881.  
  2882.  
  2883.  
  2884.  
  2885.  
  2886. _______________________________________________________________________________
  2887. Synchronet                           49                         Input Functions
  2888.  
  2889.  
  2890. Miscellaneous Functions
  2891. =======================
  2892.  
  2893. ONLINE
  2894. ------
  2895. Assume online execution (default mode), auto-return from module if user is
  2896. disconnected or logged off.
  2897.  
  2898. OFFLINE
  2899. -------
  2900. Assume offline execution, no carrier and no one online locally. If used
  2901. (for OFFLINE modules), must be the FIRST executed function of the module.
  2902.  
  2903. LOGIN <"cstr">
  2904.  args: pwprompt
  2905. ---------------
  2906. Process login attempt using the current command string as the user name/number
  2907. and pwprompt for the password prompt. This function may also prompt for the
  2908. system password with the SY: prompt if the user has level 90 or higher.
  2909.  
  2910. LOGON
  2911. -----
  2912. Logon the currently logged-in user. This function must be called before the
  2913. LOGIN module terminates if the user is to be allowed online. This function,
  2914. in turn, executs the LOGON module, if one is configured in SCFG.
  2915.  
  2916. LOGOFF
  2917. ------
  2918. This function prompts the user if they really wish to log off. If they
  2919. answer Yes, then any logoff events are executed and the LOGOFF menu file
  2920. is displayed before they are disconnected.
  2921.  
  2922. LOGOFF_FAST
  2923. -----------
  2924. This function immediately drops carrier and logs the user off. It differs
  2925. from the HANGUP function in that it performs a SYNC function, then it
  2926. immediately drops carrier, as opposed to the HANGUP function wich does not
  2927. perform a SYNC operation and has a buffer flush delay before actually
  2928. dropping carrier.
  2929.  
  2930. LOGOUT
  2931. ------
  2932. Logout the currently logged-on user. This function is used solely for
  2933. re-logging-in an already connected user.
  2934.  
  2935. NEWUSER
  2936. -------
  2937. Begins the new user application process.
  2938.  
  2939.  
  2940.  
  2941.  
  2942.  
  2943.  
  2944.  
  2945. _______________________________________________________________________________
  2946. Synchronet                           50                 Miscellaneous Functions
  2947.  
  2948.  
  2949. SET_MENU_DIR <"str">
  2950.     args: dir
  2951. ------------------
  2952. This function sets the default menu directory for the MENU function (normally
  2953. ..\TEXT\MENU). This function is useful for globally changing the directory
  2954. where MENU files will be retrieved from (including internal Synchronet
  2955. functions that can not be modified with a shell). The following is an example
  2956. of how to use this function along with the MENU function:
  2957.  
  2958.         # The next line would display ..\TEXT\MENU\MAIN.*
  2959.     MENU "MAIN"
  2960.  
  2961.         # Change the directory for menus
  2962.  
  2963.     MENU_DIR "..\TEXT\MYMENUS"
  2964.  
  2965.         # This next line would now display ..\TEXT\MYMENUS\MAIN.*
  2966.     MENU "MAIN"
  2967.  
  2968. SET_MENU_FILE <"str">
  2969.      args: path_and_filename
  2970. --------------------------------
  2971. This function is used to OVERRIDE the filename specified for a menu displayed
  2972. in an internal Synchronet function. Example:
  2973.  
  2974.     SET_MENU_FILE "..\TEXT\MYMENUS\EMAIL.RIP"
  2975.         MAIL_READ
  2976.  
  2977. SYNC
  2978. ----
  2979. This function synchronizes the local and remote displays (waits for the remote
  2980. terminal to catch up), displays any internode messages waiting for this node,
  2981. and synchronizes the current node status with the shared node database file.
  2982. It should be called before all command prompts are displayed.
  2983.  
  2984. ASYNC
  2985. -----
  2986. This function is identical to the SYNC function with the exception that any
  2987. pending output (menu, text file, etc.) can be aborted by hitting any key.
  2988.  
  2989. RIOSYNC
  2990. -------
  2991. This function synchronizes the remote console (waits for output buffers to
  2992. be sent or aborted).
  2993.  
  2994. PUT_NODE
  2995. --------
  2996. Force flush (write) of current node information (who's online, etc) to disk.
  2997.  
  2998. PAUSE_RESET
  2999. -----------
  3000. This function resets the line counter used for the automatic screen pause
  3001. feature.
  3002.  
  3003.  
  3004. _______________________________________________________________________________
  3005. Synchronet                           51                 Miscellaneous Functions
  3006.  
  3007.  
  3008. CLEAR_ABORT
  3009. -----------
  3010. This function clears the abort (Ctrl-C) status flag.
  3011.  
  3012. UNGETKEY
  3013. --------
  3014. This function puts the current command key into the input buffer to be the
  3015. next key retrieved with GETKEY, GETCMD, GETSTR, or similar functions.
  3016.  
  3017. UNGETSTR
  3018. --------
  3019. This function puts the entire contents of the current command string into the
  3020. input buffer.
  3021.  
  3022. HANGUP
  3023. ------
  3024. This function immediately disconnects and logs the user off.
  3025.  
  3026.  
  3027.  
  3028.  
  3029.  
  3030.  
  3031.  
  3032.  
  3033.  
  3034.  
  3035.  
  3036.  
  3037.  
  3038.  
  3039.  
  3040.  
  3041.  
  3042.  
  3043.  
  3044.  
  3045.  
  3046.  
  3047.  
  3048.  
  3049.  
  3050.  
  3051.  
  3052.  
  3053.  
  3054.  
  3055.  
  3056.  
  3057.  
  3058.  
  3059.  
  3060.  
  3061.  
  3062.  
  3063. _______________________________________________________________________________
  3064. Synchronet                           52                 Miscellaneous Functions
  3065.  
  3066.  
  3067. EXEC <"str">
  3068. args: cmd
  3069. ----------
  3070. This function calls the operating system to spawn the 'cmd' command line
  3071. specified. Remote users will not see or be able to interact with the program
  3072. executed unless the program is aware of the remote user and is specifically
  3073. designed to be run remotely (i.e. DOORs).
  3074.  
  3075. If an internal DOS command is to be executed, a command processor must be
  3076. loaded. Example:
  3077.  
  3078.     EXEC "COMMAND /C COPY C:\FILES\NEWFILE.TXT C:\DOWNLOADS"
  3079.  
  3080. Synchronet's command line specifiers can also be used:
  3081.  
  3082.     EXEC "%!dsz portx %u,%i sz file.zip"
  3083.  
  3084. See the Synchronet sysop manual, appendix A for a list of valid specifiers.
  3085. When used from a command shell or module, %f will be replaced with the path
  3086. to the current file directory, and %s will be replaced with the current
  3087. command string.
  3088.  
  3089. EXEC_INT <"str">
  3090.     args: cmd
  3091. --------------
  3092. This function ("Execute with I/O intercepted") is identical to the EXEC
  3093. function with the exception that DOS I/O interrupts (screen output and keyboard
  3094. input) is intercepted and redirected to the COM port if the user is logged on
  3095. remotely. This allows programs that use standard DOS I/O for screen output
  3096. to be displayed remotely. Example:
  3097.  
  3098.     EXEC_INT "COMMAND /C DIR C:\FILES\*.TXT"
  3099.  
  3100. EXEC_BIN <"str">
  3101.     args: name
  3102. --------------
  3103. This function loads and executes a Baja module. A .BIN file with the filename
  3104. specified as the 'name' argument must exist in the Synchronet EXEC directory
  3105. for this function. If for example, you want a shell to load and execute
  3106. MYMOD.BIN from your EXEC directory, you would add the following to one or more
  3107. command shells:
  3108.  
  3109.     EXEC_BIN "MYMOD"
  3110.  
  3111. EXEC_XTRN <"str">
  3112.      args: code
  3113. ---------------
  3114. This function executes the online external program specified by it's internal
  3115. code with the 'code' argument. If an online external program is not found with
  3116. a matching internal code or the user does not have access to that program, this
  3117. function does nothing.
  3118.  
  3119.  
  3120.  
  3121.  
  3122. _______________________________________________________________________________
  3123. Synchronet                           53                 Miscellaneous Functions
  3124.  
  3125.  
  3126. LOG <"cstr">
  3127. args: string
  3128. ------------
  3129. This function writes the C type 'str' argument to the system's activity log
  3130. file for the current date if the user is logged on remotely.
  3131.  
  3132. LOGSTR
  3133. ------
  3134. This function is identical to the LOG function with the exception that a
  3135. string argument is not used, but instead the current command string is written
  3136. to the system's activity log file.
  3137.  
  3138. LOGKEY
  3139. ------
  3140. This function writes the current command key to the system's activity log file
  3141. for the current date if the user is logged on remotely.
  3142.  
  3143. LOGKEY_COMMA
  3144. ------------
  3145. This function is identical to the LOGKEY function, with the exception that a
  3146. comma (,) is prepended to the command key to separate it visually from other
  3147. logged command keys.
  3148.  
  3149. NODE_STATUS <#>                         NODEDEFS.INC
  3150.        args: status
  3151. -------------------
  3152. This function is used to set the current node status. The valid status
  3153. parameters (defined in NODEDEFS.INC) are:
  3154.  
  3155. Status            Description
  3156. ~~~~~~            ~~~~~~~~~~~
  3157. NODE_WFC        Waiting for caller
  3158. NODE_LOGON        User logging on
  3159. NODE_NEWUSER        New user applying for access
  3160. NODE_INUSE        User online
  3161. NODE_QUIET        User online in quiet mode
  3162. NODE_OFFLINE        Offline (down)
  3163. NODE_NETTING        Networking
  3164. NODE_EVENT_WAITING    Waiting for another node to run timed event
  3165. NODE_EVENT_RUNNING    Running timed event
  3166. NODE_EVENT_LIMBO    Waiting for all nodes to be downed
  3167.  
  3168. Only one status parameter may be used.
  3169.  
  3170.  
  3171.  
  3172.  
  3173.  
  3174.  
  3175.  
  3176.  
  3177.  
  3178.  
  3179.  
  3180.  
  3181. _______________________________________________________________________________
  3182. Synchronet                           54                 Miscellaneous Functions
  3183.  
  3184.  
  3185. NODE_ACTION <#>                         NODEDEFS.INC
  3186.        args: action
  3187. -------------------
  3188. This function is used to set the current node action. The valid action
  3189. parameter (defined in NODEDEFS.INC) are:
  3190.  
  3191. Action        Description
  3192. ~~~~~~        ~~~~~~~~~~~
  3193. NODE_MAIN    Main Prompt
  3194. NODE_RMSG    Reading Messages
  3195. NODE_RMAL    Reading Mail
  3196. NODE_SMAL    Sending Mail
  3197. NODE_RTXT    Reading G-Files
  3198. NODE_RSML    Reading Sent Mail
  3199. NODE_PMSG    Posting Message
  3200. NODE_AMSG    Auto-message
  3201. NODE_XTRN    Running External Program
  3202. NODE_DFLT    Main Defaults Section
  3203. NODE_XFER    File Transfer Prompt
  3204. NODE_DLNG    Downloading File
  3205. NODE_ULNG    Uploading File
  3206. NODE_BXFR    Bidirectional Transfer
  3207. NODE_LFIL    Listing Files
  3208. NODE_LOGN    Logging on
  3209. NODE_LCHT    In Local Chat with Sysop
  3210. NODE_MCHT    In Multi-Chat with Other Nodes
  3211. NODE_GCHT    In Local Chat with Guru
  3212. NODE_CHAT    In Chat Section
  3213. NODE_SYSP    Sysop Activity
  3214. NODE_TQWK    Transferring QWK packet
  3215. NODE_PCHT    In Private Chat
  3216. NODE_PAGE    Paging another node for Private Chat
  3217. NODE_RFSD    Retrieving file from seq dev (node.aux=dev)
  3218.  
  3219. Only one action parameter may be used.
  3220.  
  3221. INC_MAIN_CMDS
  3222. -------------
  3223. This function increments the "main menu command" counter that can be used in
  3224. ARS comparisons.
  3225.  
  3226. INC_FILE_CMDS
  3227. -------------
  3228. This function increments the "file menu command" counter that can be used in
  3229. ARS comparisons.
  3230.  
  3231.  
  3232.  
  3233.  
  3234.  
  3235.  
  3236.  
  3237.  
  3238.  
  3239.  
  3240. _______________________________________________________________________________
  3241. Synchronet                           55                 Miscellaneous Functions
  3242.  
  3243.  
  3244. COMPARE_USER_MISC <#>                         USERDEFS.INC
  3245.          args: attrs
  3246. ------------------------
  3247. This function is used to compare the current user's miscellaneous attributess
  3248. to the attrs argument specified. If all the attrs specified are ENABLED for the
  3249. current user, then the current logic state is set to TRUE, otherwise it is set
  3250. to FALSE. One or more of the following attributess (defined in USERDEFS.INC)
  3251. can be specified:
  3252.  
  3253. Attribute       Description
  3254. ~~~~~~~~~    ~~~~~~~~~~~
  3255. UM_EXPERT    Expert menu mode
  3256. UM_DELETED    Deleted user
  3257. UM_INACTIVE    Inactive user
  3258. UM_AUTOTERM    Automatic terminal type detection
  3259. UM_ANSI     ANSI terminal
  3260. UM_COLOR    Color terminal (ANSI)
  3261. UM_RIP        RIP compatible terminal
  3262. UM_WIP        WIP compatible terminal
  3263. UM_NO_EXASCII    Extended ASCII not supported
  3264. UM_UPAUSE    Automatic screen pause
  3265. UM_SPIN     Spinning cursor
  3266. UM_ANFSCAN    Automatic new file scan
  3267. UM_CLRSCRN    Clear screen between messages
  3268. UM_QUIET    Default to quiet mode (if 'Q' exempt)
  3269. UM_BATCHFLAG    Batch flagging mode enabled
  3270. UM_NETMAIL    Forward E-mail to NetMail
  3271. UM_CURSUB    Remember current sub-board and directory
  3272. UM_ASK_NSCAN    Ask for new-scans at logon
  3273. UM_ASK_SSCAN    Ask for your message scan at logon
  3274. UM_COLDKEYS    Cold keys (CR required - opposite of Hot Keys)
  3275. UM_EXTDESC    Extended file descriptions in listings
  3276.  
  3277. Multiple attributes can be specified by ORing them together with the OR (|)
  3278. symbol. Example:
  3279.  
  3280.     COMPARE_USER_MISC UM_ANSI|UM_COLOR
  3281.  
  3282.  
  3283.  
  3284.  
  3285.  
  3286.  
  3287.  
  3288.  
  3289.  
  3290.  
  3291.  
  3292.  
  3293.  
  3294.  
  3295.  
  3296.  
  3297.  
  3298.  
  3299. _______________________________________________________________________________
  3300. Synchronet                           56                 Miscellaneous Functions
  3301.  
  3302.  
  3303. COMPARE_USER_CHAT <#>                                           USERDEFS.INC
  3304.              args: attrs
  3305. ------------------------
  3306. This function is used to compare the current user's chat attributes to the
  3307. attrs argument specified. If all the attrs specified are ENABLED for the
  3308. current user, then the current logic state is set to TRUE, otherwise it is set
  3309. to FALSE. One or more of the following attributes (defined in USERDEFS.INC) can
  3310. be specified:
  3311.  
  3312. Attribute       Description
  3313. ~~~~~~~~~    ~~~~~~~~~~~
  3314. CHAT_ECHO       Echo users input in multinode chat
  3315. CHAT_ACTION     Action commands enabled in multinode chat
  3316. CHAT_NOPAGE     This user can't be paged by other users
  3317. CHAT_NOACT      This user will not receive node activity (logon/off) alerts
  3318. CHAT_SPLITP     This user prefers split-screen private node-to-node chat
  3319.  
  3320. Multiple attributes may be specified by ORing them together with the OR (|)
  3321. symbol. Example:
  3322.  
  3323.         COMPARE_USER_CHAT CHAT_NOACT|CHAT_NOPAGE
  3324.  
  3325. COMPARE_USER_QWK <#>                        USERDEFS.INC
  3326.             args: attrs
  3327. -----------------------
  3328. This function is used to compare the current user's QWK attributes to the attrs
  3329. argument specified. If all the attrs specified are ENABLED for the current
  3330. user, then the current logic state is set to TRUE, otherwise it is set to
  3331. FALSE. One or more of the following attrs (defined in USERDEFS.INC) can be
  3332. specified:
  3333.  
  3334. Attribute       Description
  3335. ~~~~~~~~~    ~~~~~~~~~~~
  3336. QWK_FILES       Include new files list in QWK packet
  3337. QWK_EMAIL       Include unread e-mail/netmail messages in QWK packet
  3338. QWK_ALLMAIL     Include all mail in QWK packet
  3339. QWK_DELMAIL     Automatically delete packed e-mail after download
  3340. QWK_BYSELF      Include messages in QWK packet from self
  3341. QWK_EXPCTLA     Expand Ctrl-A codes in messages to ANSI
  3342. QWK_RETCTLA     Retain (keep) Ctrl-A codes in messages
  3343. QWK_ATTACH      Include file attachments in QWK packet
  3344. QWK_NOINDEX     Do not include .NDX files in QWK packet
  3345. QWK_TZ          Include time zone (@TZ) in messages
  3346. QWK_VIA         Include message path (@VIA) in messages
  3347. QWK_NOCTRL      Do not include control files (DOOR.ID, CONTROL.DAT, etc)
  3348.  
  3349. Multiple attributes may be specified by ORing them together with the OR (|)
  3350. symbol. Example:
  3351.  
  3352.     COMAPARE_USER_QWK QWK_TZ|QWK_VIA
  3353.  
  3354.  
  3355.  
  3356.  
  3357.  
  3358. _______________________________________________________________________________
  3359. Synchronet                           57                 Miscellaneous Functions
  3360.  
  3361.  
  3362. COMPARE_NODE_MISC <#>                        NODEDEFS.INC
  3363.              args: attrs
  3364. ------------------------
  3365. This function is used to compare the current node's misc attributes to the
  3366. attrs argument specified. If all the attrs specified are ENABLED for the
  3367. current node, then the current logic state is set to TRUE, otherwise it is set
  3368. to FALSE. The valid attributes (defined in NODEDEFS.INC) are:
  3369.  
  3370. Attribute    Description
  3371. ~~~~~~~~~    ~~~~~~~~~~~
  3372. NODE_ANON    Anonymous node
  3373. NODE_LOCK    Locked node (sysop's and N exempt users only)
  3374. NODE_INTR    Interrupted node (log user off ASAP)
  3375. NODE_MSGW    Short message waiting for this node
  3376. NODE_POFF    Not available for paging
  3377. NODE_AOFF    No node activity alerts
  3378. NODE_UDAT    User data has been updated by another node
  3379. NODE_RRUN    Re-run this node after user logs off
  3380. NODE_EVENT    Run node daily event after user logs off
  3381. NODE_DOWN    Down this node after user logs off
  3382. NODE_NMSG    Node message waiting for this node
  3383. NODE_EXT    Extended status information available for this node
  3384.  
  3385. Multiple attributes may be specified by ORing them together with the OR (|)
  3386. symbol. Example:
  3387.  
  3388.     COMPARE_NODE_MISC NODE_DOWN|NODE_INTR
  3389.  
  3390. TOGGLE_USER_MISC <#>                           USERDEFS.INC
  3391.         args: attrs
  3392. -----------------------
  3393. This function is used to toggle specific attributes on or off for the current
  3394. user. The valid attrs for the argument are identical to those used for the
  3395. COMPARE_USER_MISC function.
  3396.   
  3397. You cannot specify if you want the attribute turned ON or OFF with this
  3398. command. Use in combination with the COMPARE_USER_MISC function to specifically
  3399. enable or disable a user's attribute. Example to turn the NETMAIL misc attr OFF
  3400. for the current user:
  3401.  
  3402.         !INCLUDE USERDEFS.INC
  3403.     COMPARE_USER_MISC UM_NETMAIL
  3404.         IF_TRUE
  3405.         TOGGLE_USER_MISC UM_NETMAIL
  3406.                 END_IF
  3407.  
  3408.  
  3409.  
  3410.  
  3411.  
  3412.  
  3413.  
  3414.  
  3415.  
  3416.  
  3417. _______________________________________________________________________________
  3418. Synchronet                           58                 Miscellaneous Functions
  3419.  
  3420.  
  3421. TOGGLE_USER_CHAT <#>                        USERDEFS.INC
  3422.             args: attrs
  3423. -----------------------
  3424. This function is used to toggle specific chat attributes on or off for the
  3425. current user.  The valid attrs for the argument are identical to
  3426. those used for the COMPARE_USER_CHAT function.
  3427.  
  3428. You cannot specify if you want the attribute turned ON or OFF with this
  3429. command. Use in combination with the COMPARE_USER_CHAT function to specifically
  3430. enable or disable a chat attribute. Example to turn the Split Screen Private
  3431. Chat (CHAT_SPLITP) attribute OFF for the current user:
  3432.  
  3433.     COMPARE_USER_CHAT CHAT_SPLITP
  3434.         IF_TRUE
  3435.         TOGGLE_USER_CHAT CHAT_SPLITP
  3436.                 END_IF
  3437.  
  3438. TOGGLE_USER_QWK <#>                        USERDEFS.INC
  3439.        args: attrs
  3440. ----------------------
  3441. This function is used to toggle specific QWK attributes on or off for the
  3442. current user. The valid attrs for the argument are identical to those used for
  3443. the COMPARE_USER_QWK function.
  3444.  
  3445. You cannot specify if you want the attr turned ON or OFF with this command. Use
  3446. in combination with the COMPARE_USER_QWK function to specifically enable or
  3447. disable a QWK attribute.
  3448.  
  3449. TOGGLE_NODE_MISC <#>                        NODEDEFS.INC
  3450.         args: attrs
  3451. -----------------------
  3452. This function is used to toggle the miscellaneous attributes associated with
  3453. the current node. The valid attrs for the argument are identical to those used
  3454. for the COMPARE_NODE_MISC function.
  3455.  
  3456. TOGGLE_USER_FLAG <char> <char>
  3457.         args: set     flag
  3458. -----------------------------
  3459. This function is used to toggle the state of one of the current user's flags.
  3460. The first argument is a single character indicating the flag set. Valid
  3461. flag sets are 1, 2, 3, 4, or E for exemption, or R for restriction. The
  3462. second argument is the actual flag character to toggle (A through Z).
  3463.  
  3464.  
  3465.  
  3466.  
  3467.  
  3468.  
  3469.  
  3470.  
  3471.  
  3472.  
  3473.  
  3474.  
  3475.  
  3476. _______________________________________________________________________________
  3477. Synchronet                           59                 Miscellaneous Functions
  3478.  
  3479.  
  3480. ADJUST_USER_CREDITS <#>
  3481.            args: adj
  3482. ------------------------
  3483. This function is used to add or subtract credits from the current user. The
  3484. 'adj' argument must be either a positive or negative number (in Kilobytes).
  3485. Example, to subtract 100K in credits from the current user:
  3486.  
  3487.         ADJUST_USER_CREDITS -100
  3488.  
  3489. ADJUST_USER_MINUTES <#>
  3490.            args: adj
  3491. ------------------------
  3492. This function is used to add or subtract minutes from the current user's
  3493. minute bank. The 'adj' argument must be either a positive or negative number.
  3494. Example, to subtract 60 minutes from the current user:
  3495.  
  3496.     ADJUST_USER_MINUTES -60
  3497.  
  3498. SET_USER_LEVEL <#>
  3499.       args: level
  3500. ---------------------
  3501. This function changes the current user's security level to the number passed
  3502. as the argument.
  3503.  
  3504.  
  3505.  
  3506.  
  3507.  
  3508.  
  3509.  
  3510.  
  3511.  
  3512.  
  3513.  
  3514.  
  3515.  
  3516.  
  3517.  
  3518.  
  3519.  
  3520.  
  3521.  
  3522.  
  3523.  
  3524.  
  3525.  
  3526.  
  3527.  
  3528.  
  3529.  
  3530.  
  3531.  
  3532.  
  3533.  
  3534.  
  3535. _______________________________________________________________________________
  3536. Synchronet                           60                 Miscellaneous Functions
  3537.  
  3538.  
  3539. SET_USER_STRING <#>                        USERDEFS.INC
  3540.        args: user_string
  3541. ----------------------------
  3542. This fucntion changes one of the current user's text string fields to the
  3543. value of the current command string. The user_string argument must be one of
  3544. the following (defined in USERDEFS.INC):
  3545.  
  3546. User_string        Description
  3547. ~~~~~~~~~~~        ~~~~~~~~~~~
  3548. USER_STRING_ALIAS    User's alias or real name on real name based BBSs
  3549. USER_STRING_REALNAME    User's real name or company name
  3550. USER_STRING_HANDLE    User's chat handle
  3551. USER_STRING_COMPUTER    User's computer type description
  3552. USER_STRING_NOTE    User's note/Caller-ID
  3553. USER_STRING_ADDRESS    User's street address
  3554. USER_STRING_LOCATION    User's city, state
  3555. USER_STRING_ZIPCODE    User's zip/postal code
  3556. USER_STRING_PASSWORD    User's password
  3557. USER_STRING_BIRTHDAY    User's birthday (MM/DD/YY or DD/MM/YY)
  3558. USER_STRING_PHONE    User's phone number
  3559. USER_STRING_MODEM    User's modem type description
  3560. USER_STRING_COMMENT    User's secret sysop comment
  3561.  
  3562. USER_EVENT <#>                            SBBSDEFS.INC
  3563.       args: event_type
  3564. ----------------------
  3565. This function forces immediate execution of all online events for the specified
  3566. event_type. The valid event_types (defined in SBBSDEFS.INC) are:
  3567.  
  3568. Event_type        Description
  3569. ~~~~~~~~~~        ~~~~~~~~~~~
  3570. EVENT_LOGON        Execute during logon sequence
  3571. EVENT_NEWUSER        Execute during newuser app.
  3572. EVENT_BIRTHDAY        Execute on birthday
  3573. EVENT_LOGOFF        Execute during normal logoff
  3574.  
  3575. AUTO_MESSAGE
  3576. ------------
  3577. This function allows the user to read and write to the auto-message. If the
  3578. user has the 'W' restriction, they will not be allowed to write to the
  3579. auto-message.
  3580.  
  3581. USER_DEFAULTS
  3582. -------------
  3583. This function takes the user to the default configuration menu where they
  3584. can modify their default settings (e.g. Terminal type, Command Shell, etc).
  3585. If the user selects a new command shell while in this function, the new
  3586. shell is loaded and executed immediately (from the top) instead of resuming
  3587. with the shell that originally called this function.
  3588.  
  3589.  
  3590.  
  3591.  
  3592.  
  3593.  
  3594. _______________________________________________________________________________
  3595. Synchronet                           61                 Miscellaneous Functions
  3596.  
  3597.  
  3598. USER_EDIT
  3599. ---------
  3600. This function is used to edit the user information for the user name or number
  3601. specified in the current command string. Since almost all user information can
  3602. be changed and other users can be edited from this section, this is normally
  3603. reserved as a "sysop only" operation.
  3604.  
  3605. TEXT_FILE_SECTION
  3606. -----------------
  3607. This function takes the user to the General Text File section of the system.
  3608.  
  3609. XTRN_EXEC
  3610. ---------
  3611. This function is identical to the EXEC_XTRN function with the exception that
  3612. the external program's internal code is contained in the current command string
  3613. instead of an argument.
  3614.  
  3615. XTRN_SECTION
  3616. ------------
  3617. This function takes the user to the external program section of the system.
  3618.  
  3619. MINUTE_BANK
  3620. -----------
  3621. This function allows the user to convert credits into minutes, or deposit
  3622. unused free minutes (if allowed) in their minute bank.
  3623.  
  3624. CHANGE_USER
  3625. -----------
  3626. This function prompts the user for the system password and if entered
  3627. correctly, then prompts them for the user name or number to change into.
  3628. This is normally reserved as a "sysop only" operation. After changing into
  3629. a "non-sysop" user, the temp sysop status is set so the user may change back
  3630. into the original or another user.
  3631.  
  3632. ANSI_CAPTURE
  3633. ------------
  3634. This function enables the capture of ANSI terminal escape sequences when the
  3635. local capture (Alt-L) is in use. This is normally reserved as a "sysop only"
  3636. operation.
  3637.  
  3638. FINDUSER
  3639. --------
  3640. Scans the user database for the user name or partial name in the current
  3641. command string. If the name is found, the logic state is set to TRUE. If the
  3642. name is not found, it is set to FALSE.
  3643.  
  3644. SELECT_SHELL
  3645. ------------
  3646. This function displays a list of the available command shells and allows the
  3647. user to choose a command shell. If a shell is not selected, the logic state
  3648. is set to FALSE.
  3649.  
  3650.  
  3651.  
  3652.  
  3653. _______________________________________________________________________________
  3654. Synchronet                           62                 Miscellaneous Functions
  3655.  
  3656.  
  3657. SET_SHELL
  3658. ---------
  3659. This function attempts to set the current user's shell to the internal code
  3660. contained in the current command string. If the internal code is not valid or
  3661. the user does not have access to that shell, the logic state is set to FALSE.
  3662.  
  3663. SELECT_EDITOR
  3664. ------------
  3665. This function displays a list of the available external editors and allows the
  3666. user to choose an editor. If an editor is not selected, the logic state
  3667. is set to FALSE.
  3668.  
  3669. SET_EDITOR
  3670. ----------
  3671. This function attempts to set the current user's editor to the internal code
  3672. contained in the current command string. If the internal code is not valid or
  3673. the user does not have access to that external editor, the logic state is set
  3674. to FALSE.
  3675.  
  3676. TRASHCAN <"str">
  3677.     args: file
  3678. --------------
  3679. This function opens the file TEXT\file.CAN and searches for the current
  3680. command string. If the string is found in the file the current logic state is
  3681. set to TRUE and if the file TEXT\BADfile.MSG exists, it is automatically
  3682. displayed to the user. If the string is not found, the logic state is set to
  3683. FALSE.
  3684.  
  3685. If a line in the .CAN file ends in a tilde (~), the contents of the line may
  3686. be found anywhere in the tested string and result in a TRUE logic state.
  3687.  
  3688. If a line in the .CAN file ends in a caret (^), the contents of the line must
  3689. begin the tested string to result in a TRUE logic state.
  3690.  
  3691. GETTIMELEFT
  3692. -----------
  3693. Checks the user's current time left online and disconnects the user (with a
  3694. message) if they're out of time.
  3695.  
  3696. MSWAIT <#>
  3697.   args: num
  3698. -----------
  3699. Suspends execution for num milliseconds (gives up time-slices).
  3700.  
  3701. SEND_FILE_VIA <char> <"str" or str_var>
  3702.      args: prot   path_and_filename
  3703. ---------------------------------------
  3704. Immediately begins a transfer of a file from the local disk (path_and_filename)
  3705. to the remote user using the specified protocol (prot must match the command
  3706. key of one of the configured protocols in SCFG).
  3707.  
  3708.  
  3709.  
  3710.  
  3711.  
  3712. _______________________________________________________________________________
  3713. Synchronet                           63                 Miscellaneous Functions
  3714.  
  3715.  
  3716. RECEIVE_FILE_VIA <char> <"str" or str_var>
  3717.      args: prot   path_and_filename
  3718. ---------------------------------------
  3719. Immediately begins a transfer of a file from the remote user using the
  3720. specified protocol (prot must match the command key of one of the configured
  3721. protocols in SCFG). The path_and_filename variable may be set to a directory
  3722. name for protocols that don't require a specified filename (i.e. Ymodem,
  3723. Zmodem, etc - NOT Xmodem). [SBBS 2.3]
  3724.  
  3725.  
  3726.  
  3727.  
  3728.  
  3729.  
  3730.  
  3731.  
  3732.  
  3733.  
  3734.  
  3735.  
  3736.  
  3737.  
  3738.  
  3739.  
  3740.  
  3741.  
  3742.  
  3743.  
  3744.  
  3745.  
  3746.  
  3747.  
  3748.  
  3749.  
  3750.  
  3751.  
  3752.  
  3753.  
  3754.  
  3755.  
  3756.  
  3757.  
  3758.  
  3759.  
  3760.  
  3761.  
  3762.  
  3763.  
  3764.  
  3765.  
  3766.  
  3767.  
  3768.  
  3769.  
  3770.  
  3771. _______________________________________________________________________________
  3772. Synchronet                           64                 Miscellaneous Functions
  3773.  
  3774.  
  3775. Mail Functions
  3776. ==============
  3777.  
  3778. The following functions are related to private E-mail.
  3779.  
  3780. MAIL_READ
  3781. ---------
  3782. This function retrieves and displays mail waiting in the mail-box of the
  3783. current user, if any.
  3784.  
  3785. MAIL_READ_SENT
  3786. --------------
  3787. This function retrieves and displays mail that the current user has sent and
  3788. is still pending deletion in the mail-box(es) of the recipient(s).
  3789.  
  3790. MAIL_READ_ALL
  3791. -------------
  3792. This function retrieves and displays all the e-mail on the system. This
  3793. function is normally reserved as a "sysop only" operation.
  3794.  
  3795. MAIL_SEND
  3796. ---------
  3797. This function attempts to send mail to the user specified by the current
  3798. command string. If the user name or number specified in the string cannot be
  3799. located, the operation is aborted and the current logic state is set to FALSE.
  3800. If the user name or number is located, the current logic state is set to TRUE.
  3801. Example usage:
  3802.  
  3803.         PRINT "Send mail to who? "
  3804.         GETNAME 25
  3805.         MAIL_SEND
  3806.  
  3807. MAIL_SEND_FILE
  3808. --------------
  3809. This function is identical to the MAIL_SEND function with the exception that
  3810. a file attachment is included with the mail message.
  3811.  
  3812. MAIL_SEND_BULK
  3813. --------------
  3814. This function is used to send bulk (multiple destination) mail. The function
  3815. is normally reserved as a "sysop only" operation, but some sysops may want
  3816. some or all users to have the ability to send bulk mail.
  3817.  
  3818. MAIL_SEND_FEEDBACK
  3819. ------------------
  3820. This function is identical to the MAIL_SEND function with the exception that
  3821. "Re: Feedback" is placed at the top of the mail message.
  3822.  
  3823.  
  3824.  
  3825.  
  3826.  
  3827.  
  3828.  
  3829.  
  3830. _______________________________________________________________________________
  3831. Synchronet                           65                          Mail Functions
  3832.  
  3833.  
  3834. MAIL_SEND_NETMAIL
  3835. -----------------
  3836. This function prompts the user for a user name and netmail address. If the
  3837. user just hits CR, the current logic state is set to FALSE, otherwise a NetMail
  3838. operation is attempted and the logic state is set to TRUE.
  3839.  
  3840. MAIL_SEND_NETFILE
  3841. -----------------
  3842. This function is identical to the MAIL_SEND_NETMAIL function with the exception
  3843. that if the NetMail file attachments are allowed, this function will allow the
  3844. user to send an attached file to a netmail message (for FidoNet or Internet).
  3845.  
  3846.  
  3847.  
  3848.  
  3849.  
  3850.  
  3851.  
  3852.  
  3853.  
  3854.  
  3855.  
  3856.  
  3857.  
  3858.  
  3859.  
  3860.  
  3861.  
  3862.  
  3863.  
  3864.  
  3865.  
  3866.  
  3867.  
  3868.  
  3869.  
  3870.  
  3871.  
  3872.  
  3873.  
  3874.  
  3875.  
  3876.  
  3877.  
  3878.  
  3879.  
  3880.  
  3881.  
  3882.  
  3883.  
  3884.  
  3885.  
  3886.  
  3887.  
  3888.  
  3889. _______________________________________________________________________________
  3890. Synchronet                           66                          Mail Functions
  3891.  
  3892.  
  3893. Message Base Functions
  3894. ======================
  3895.  
  3896. The following functions are related to the system's message base.
  3897.  
  3898. MSG_SET_AREA
  3899. ------------
  3900. This function uses the current command string to search all sub-boards the
  3901. current user has access to for an internal code matching the current command
  3902. string. If the internal code is found, that sub-board becomes the current
  3903. sub-board and the current logic state is set to TRUE, otherwise it is set to
  3904. FALSE and the current sub-board remains unchanged.
  3905.  
  3906. MSG_SET_GROUP
  3907. -------------
  3908. This function uses the current command string to search all message groups the
  3909. current user has access to for a short name matching the current command
  3910. string. If the short name is found, that group becomes the current group and
  3911. the current logic state is set to TRUE, otherwise it is set to FALSE and the
  3912. current group remains unchanged.
  3913.  
  3914. MSG_SELECT_AREA
  3915. ---------------
  3916. This function prompts the user to select a message group (if the user has
  3917. access to more than one) and sub-board. If the user aborts the selection,
  3918. the current logic state is set to FALSE and the current sub-board is unchanged.
  3919. Otherwise, the logic state is set to TRUE and the selected sub-board becomes
  3920. the current sub-board.
  3921.  
  3922. MSG_SHOW_GROUPS
  3923. ---------------
  3924. This function displays a list of message groups the current user has access to.
  3925.  
  3926. MSG_SHOW_SUBBOARDS
  3927. ------------------
  3928. This function displays a list of sub-boards within the current message group
  3929. that the user has access to.
  3930.  
  3931. MSG_GROUP_UP
  3932. ------------
  3933. This function moves the current message group up by one. If already at the
  3934. highest group, then it wraps to the first group.
  3935.  
  3936. MSG_GROUP_DOWN
  3937. --------------
  3938. This function is the opposite of the MSG_GROUP_UP function.
  3939.  
  3940.  
  3941.  
  3942.  
  3943.  
  3944.  
  3945.  
  3946.  
  3947.  
  3948. _______________________________________________________________________________
  3949. Synchronet                           67                  Message Base Functions
  3950.  
  3951.  
  3952. MSG_SUBBOARD_UP
  3953. ---------------
  3954. This function moves the current message sub-board up by one. If already at
  3955. the highest sub-board in the current group, it wraps to the first sub-board
  3956. in the current group.
  3957.  
  3958. MSG_SUBBOARD_DOWN
  3959. -----------------
  3960. This function is the opposite of the MSG_SUBBOARD_UP function.
  3961.  
  3962. MSG_GET_SUB_NUM
  3963. ---------------
  3964. This function accepts a number from the user to change the current sub-board.
  3965.  
  3966. MSG_GET_GRP_NUM
  3967. ---------------
  3968. This function accepts a number from the user to change the current message
  3969. group.
  3970.  
  3971. MSG_READ
  3972. --------
  3973. This function is used to read messages in the current sub-board. If the
  3974. read is aborted, the current logic state is set to FALSE, otherwise it is set
  3975. to TRUE.
  3976.  
  3977. MSG_POST
  3978. --------
  3979. This function attempts to post a message on the current sub-board. If the user
  3980. does not have posting access on the current sub-board or the post is aborted,
  3981. the current logic state is set to FALSE, otherwise it is set to TRUE.
  3982.  
  3983. MSG_QWK
  3984. -------
  3985. This function puts the user in the QWK message packet section.
  3986.  
  3987. MSG_PTRS_CFG
  3988. ------------
  3989. This function allows the user to manipulate their new-message scan pointers.
  3990.  
  3991. MSG_PTRS_REINIT
  3992. ---------------
  3993. This function resets the user's new-message scan pointers to their value at
  3994. logon.
  3995.  
  3996. MSG_NEW_SCAN_CFG
  3997. ----------------
  3998. This function allows the user to manipulate their new-message scan
  3999. configuration.
  4000.  
  4001. MSG_NEW_SCAN
  4002. ------------
  4003. This function performs a new message scan on either the current sub-board,
  4004. current message group, or all sub-boards.
  4005.  
  4006.  
  4007. _______________________________________________________________________________
  4008. Synchronet                           68                  Message Base Functions
  4009.  
  4010.  
  4011. MSG_NEW_SCAN_ALL
  4012. ----------------
  4013. This function performs a new message scan on all sub-boards.
  4014.  
  4015. MSG_NEW_SCAN_SUB
  4016. ----------------
  4017. This function performs a new message scan on the current sub-board. If the
  4018. new-scan is aborted, the current logic state is set to FALSE.
  4019.  
  4020. MSG_CONT_SCAN
  4021. -------------
  4022. This function performs a continuous new message scan on either the current
  4023. sub-board, current message group, or all sub-boards.
  4024.  
  4025. MSG_CONT_SCAN_ALL
  4026. -----------------
  4027. This function performs a continuous new message scan on all sub-boards.
  4028.  
  4029. MSG_BROWSE_SCAN
  4030. ---------------
  4031. This function is identical to the MSG_NEW_SCAN function, with the exception
  4032. that if there are no new messages in a sub-board, the last message posted
  4033. will be displayed.
  4034.  
  4035. MSG_BROWSE_SCAN_ALL
  4036. -------------------
  4037. This function performs a browse scan on all sub-boards.
  4038.  
  4039. MSG_FIND_TEXT
  4040. -------------
  4041. This function prompts for a search string from the user and searches the
  4042. current sub-board, current group, or all sub-boards for the text.
  4043.  
  4044. MSG_FIND_TEXT_ALL
  4045. -----------------
  4046. This function performs a text search on all sub-boards.
  4047.  
  4048. MSG_YOUR_SCAN_CFG
  4049. -----------------
  4050. This function allows the user to configure their un-read personal message
  4051. scan.
  4052.  
  4053. MSG_YOUR_SCAN
  4054. -------------
  4055. This function peforms an un-read personal message scan on the current
  4056. sub-board, current message group, or all sub-boards.
  4057.  
  4058. MSG_YOUR_SCAN_ALL
  4059. -----------------
  4060. This function peforms an un-read personal message scan on all sub-boards.
  4061.  
  4062.  
  4063.  
  4064.  
  4065.  
  4066. _______________________________________________________________________________
  4067. Synchronet                           69                  Message Base Functions
  4068.  
  4069.  
  4070. File Base Functions
  4071. ===================
  4072.  
  4073. FILE_SET_AREA
  4074. -------------
  4075. This function uses the current command string to search all directories the
  4076. current user has access to for an internal code matching the current command
  4077. string. If the internal code is found, that directory becomes the current
  4078. directory and the current logic state is set to TRUE, otherwise it is set to
  4079. FALSE and the current directory remains unchanged.
  4080.  
  4081. FILE_SET_LIBRARY
  4082. ----------------
  4083. This function uses the current command string to search all libraries the
  4084. current user has access to for a short name matching the current command
  4085. string. If the short name is found, that library becomes the current library
  4086. and the current logic state is set to TRUE, otherwise it is set to FALSE and
  4087. the current library remains unchanged.
  4088.  
  4089. FILE_SELECT_AREA
  4090. ---------------
  4091. This function prompts the user to select a file library (if the user has
  4092. access to more than one) and directory. If the user aborts the selection,
  4093. the current logic state is set to FALSE the current directory is unchanged.
  4094. Otherwise, the logic state is set to TRUE and the selected directory becomes
  4095. the current directory.
  4096.  
  4097. FILE_SHOW_LIBRARIES
  4098. -------------------
  4099. This function displays a list of all file libraries the current user has
  4100. access to.
  4101.  
  4102. FILE_SHOW_DIRECTORIES
  4103. ---------------------
  4104. This function displays a list of all directories within the current library
  4105. that the user has access to.
  4106.  
  4107. FILE_LIBRARY_UP
  4108. ---------------
  4109. This function increments the current file library. If already at the last
  4110. library, it will wrap to the first library.
  4111.  
  4112. FILE_LIBRARY_DOWN
  4113. -----------------
  4114. This function is the opposite of the FILE_LIBRARY_UP function.
  4115.  
  4116. FILE_DIRECTORY_UP
  4117. -----------------
  4118. This function increments the current file directory. If already at the last
  4119. directory in the current library, it will wrap to the first directory of the
  4120. library.
  4121.  
  4122.  
  4123.  
  4124.  
  4125. _______________________________________________________________________________
  4126. Synchronet                           70                     File Base Functions
  4127.  
  4128.  
  4129. FILE_DIRECTORY_DOWN
  4130. -------------------
  4131. This function is the opposite of the FILE_DIRECTORY_UP function.
  4132.  
  4133. FILE_GET_DIR_NUM
  4134. ----------------
  4135. This function waits for the user to enter a number to be used to change the
  4136. current file directory.
  4137.  
  4138. FILE_GET_LIB_NUM
  4139. ----------------
  4140. This function waits for the user to enter a number to be used to change the
  4141. current file library.
  4142.  
  4143. FILE_LIST
  4144. ---------
  4145. This function displays the contents matching the filespec contained in the
  4146. current command string of the current file directory. If the listing is
  4147. aborted, the current logic state is set to FALSE, otherwise it is set to TRUE.
  4148. Example:
  4149.  
  4150.         GETFILESPEC
  4151.         IF_TRUE
  4152.                 FILE_LIST
  4153.                 END_IF
  4154.  
  4155. FILE_LIST_EXTENDED
  4156. ------------------
  4157. This function displays the extended information about the files in the current
  4158. directory that match the filespec contained in the current command string.
  4159.  
  4160. FILE_VIEW
  4161. ---------
  4162. This function views the contents of the files that match the filespec in the
  4163. current command string.
  4164.  
  4165. FILE_UPLOAD
  4166. -----------
  4167. This function attempts to upload to the current file directory. If the user
  4168. cannot upload for some reason, the current logic state is set to FALSE.
  4169. Otherwise, it is set to TRUE.
  4170.  
  4171. FILE_UPLOAD_USER
  4172. ----------------
  4173. This function allows a user to upload a file specifically to another user,
  4174. provided the sysop has created a "User" file transfer directory for
  4175. user-to-user transfers. If the user cannot upload to the user directory or one
  4176. doesn't exist, the current logic state is set to FALSE, otherwise it set to
  4177. TRUE.
  4178.  
  4179.  
  4180.  
  4181.  
  4182.  
  4183.  
  4184. _______________________________________________________________________________
  4185. Synchronet                           71                     File Base Functions
  4186.  
  4187.  
  4188. FILE_UPLOAD_SYSOP
  4189. -----------------
  4190. This function allows the user to upload a file to the invisible sysop
  4191. directory. If ther user does not have upload access to the sysop directory or a
  4192. sysop directory has not been created, the current logic state is set to FALSE,
  4193. otherwise, it is set to TRUE.
  4194.  
  4195. FILE_DOWNLOAD
  4196. -------------
  4197. This function attempts to download all files matching the filespec contained
  4198. in the current command string.
  4199.  
  4200. FILE_DOWNLOAD_USER
  4201. ------------------
  4202. This function attempts to download any user-to-user files pending for the
  4203. current user. If there are no files waiting for the user or the user does not
  4204. have download access to the user directory, the current logic state is set
  4205. to FALSE, otherwise it is set to TRUE.
  4206.  
  4207. FILE_DOWNLOAD_BATCH
  4208. -------------------
  4209. This function attempts to download any files in the batch download queue.
  4210. If there are no files in the queue or the user answers No to the question if
  4211. they wish to download the files now, then the current logic state is set to
  4212. FALSE. If there are files in the queue and the user answers Yes to the question
  4213. if they wish to download the files, then the logic state is set to TRUE.
  4214.  
  4215. FILE_REMOVE
  4216. -----------
  4217. This function attempts to remove any files the user has uploaded (unless
  4218. R exempt) that match the filespec contained in the current command string.
  4219.  
  4220. FILE_BATCH_ADD
  4221. --------------
  4222. This function attempts to add the filename contained in the current command
  4223. string to the batch download queue. If the filename is not found, the current
  4224. logic state is set to FALSE.
  4225.  
  4226. FILE_BATCH_ADD_LIST
  4227. -------------------
  4228. This function opens the list file specified in the current command string and
  4229. attempts to add each filename (one filename per line) to the current user's
  4230. batch download queue. After the list file is read, it is automatically deleted.
  4231.  
  4232. FILE_BATCH_CLEAR
  4233. ----------------
  4234. This function clears the current batch download queue.
  4235.  
  4236. FILE_BATCH_SECTION
  4237. ------------------
  4238. This function takes the user to the Batch/Bi-dir transfer menu where they
  4239. can edit the batch queues and initiate batch or bi-directional file transfers.
  4240.  
  4241.  
  4242.  
  4243. _______________________________________________________________________________
  4244. Synchronet                           72                     File Base Functions
  4245.  
  4246.  
  4247. FILE_TEMP_SECTION
  4248. -----------------
  4249. This function takes the user to the temporary archive menu where they can
  4250. extract archives, create file listings, and compress temporary files for
  4251. download.
  4252.  
  4253. FILE_NEW_SCAN
  4254. -------------
  4255. This function scans the current directory, current library, or all directories
  4256. for new files.
  4257.  
  4258. FILE_NEW_SCAN_ALL
  4259. -----------------
  4260. This function scans all directories for new files.
  4261.  
  4262. FILE_FIND_TEXT
  4263. --------------
  4264. This function prompts the user to enter a search string which is used in a
  4265. text search of all file descriptions in the current directory, current library,
  4266. or all directories.
  4267.  
  4268. FILE_FIND_TEXT_ALL
  4269. ------------------
  4270. This function prompts the user for a search string to use in a text search
  4271. of file descriptions in all directories.
  4272.  
  4273. FILE_FIND_NAME
  4274. --------------
  4275. This function prompts the user for a filespec and searches the current
  4276. directory, current library, or all directories for files matching the
  4277. specification.
  4278.  
  4279. FILE_FIND_NAME_ALL
  4280. ------------------
  4281. This function prompts the user for a filespec and searches all directories for
  4282. files matching that specification.
  4283.  
  4284. FILE_PTRS_CFG
  4285. -------------
  4286. This function allows the user to change their new file scan date/time. If the
  4287. pointer is changed, the current logic state is set to TRUE, otherwise it is
  4288. set to FALSE.
  4289.  
  4290. FILE_SET_ALT_PATH
  4291. -----------------
  4292. This function sets the current upload path to the alternate path number
  4293. contained in the current command string. This function is normally reserved as
  4294. a "sysop only" operation, used to upload files on CD-ROM in most cases.
  4295.  
  4296.  
  4297.  
  4298.  
  4299.  
  4300.  
  4301.  
  4302. _______________________________________________________________________________
  4303. Synchronet                           73                     File Base Functions
  4304.  
  4305.  
  4306. FILE_RESORT_DIRECTORY
  4307. ---------------------
  4308. This function is used to resort (if directory sort order or type has changed)
  4309. and compress (if any deleted file slots exist) the current directory, current
  4310. library or all directories. All other nodes must be inactive for this function
  4311. to work. The current command string must be set (with SETSTR, GETSTR, or
  4312. similar function) to "ALL" (resort all directories), "LIB" (resort current
  4313. library), or "" (current directory only).
  4314.  
  4315. FILE_GET
  4316. --------
  4317. This function is used to remotely download a file that is not in the file
  4318. database. This function is normally reserved as a "sysop only" operation.
  4319. The path and filename to be downloaded are contained in the current command
  4320. string.
  4321.  
  4322. FILE_SEND
  4323. ---------
  4324. Same as FILE_GET, but doesn't require system password.
  4325.  
  4326. FILE_PUT
  4327. --------
  4328. This function is used to remotely upload a file to the system's hard disk,
  4329. but not place the file in the file database. This is normally reserved as a
  4330. "sysop only" operation. The path and filename to be uploaded are contained in
  4331. the current command string.
  4332.  
  4333. FILE_UPLOAD_BULK
  4334. ----------------
  4335. This function is used to do a local bulk upload of files that are in the
  4336. physical DOS directory, but not already in the file database. This is normally
  4337. reserved as a "sysop only" operation. If the current command string is set to
  4338. "ALL", then all directories will be scanned, "LIB" then only the current
  4339. library, and "" indicates only the current directory.
  4340.  
  4341. FILE_FIND_OLD
  4342. -------------
  4343. This function is used to search directories for files that have not be
  4344. downloaded since the current new file scan date (set with FILE_PTRS_CFG).
  4345. For each file that is found, the user is prompted if they wish to remove the
  4346. file. This is normally reserved as a "sysop only" operation. If the current
  4347. string is set to "ALL", then all directories will be scanned "LIB" indicates
  4348. only the current library, and "" indicates only the current directory.
  4349.  
  4350. FILE_FIND_OPEN
  4351. --------------
  4352. This function searches for file records that are currently open. This function
  4353. should not be used with other nodes in use. For each open file that is found,
  4354. the user is prompted if they wish to close the file record. As with the
  4355. FILE_FIND_OLD function, the current command string must contain "ALL", "LIB",
  4356. or "" to specify the search range.
  4357.  
  4358.  
  4359.  
  4360.  
  4361. _______________________________________________________________________________
  4362. Synchronet                           74                     File Base Functions
  4363.  
  4364.  
  4365. FILE_FIND_OFFLINE
  4366. -----------------
  4367. This function searches for files that are in the database, but not in the
  4368. physical DOS directory. For each missing file that is found, the user is
  4369. prompted if they wish to move or remove the file. This normally reserved as a
  4370. "sysop only" operation. As with the FILE_FIND_OLD function, the current command
  4371. string must contain "ALL", "LIB", or "" to specify the search range.
  4372.  
  4373. FILE_FIND_OLD_UPLOADS
  4374. ---------------------
  4375. This function searches for files that were uploaded before the current new
  4376. scan date (set with FILE_PTRS_CFG). For each file that is found, the user is
  4377. prompted if they wish to remove the file. This is normally reserved as a "sysop
  4378. only" operation. As with the FILE_FIND_OLD function, the current command string
  4379. must contain "ALL", "LIB", or "" to specify the search range.
  4380.  
  4381.  
  4382.  
  4383.  
  4384.  
  4385.  
  4386.  
  4387.  
  4388.  
  4389.  
  4390.  
  4391.  
  4392.  
  4393.  
  4394.  
  4395.  
  4396.  
  4397.  
  4398.  
  4399.  
  4400.  
  4401.  
  4402.  
  4403.  
  4404.  
  4405.  
  4406.  
  4407.  
  4408.  
  4409.  
  4410.  
  4411.  
  4412.  
  4413.  
  4414.  
  4415.  
  4416.  
  4417.  
  4418.  
  4419.  
  4420. _______________________________________________________________________________
  4421. Synchronet                           75                     File Base Functions
  4422.  
  4423.  
  4424. Chat Functions
  4425. ==============
  4426.  
  4427. The following functions are chat related in nature.
  4428.  
  4429. PAGE_SYSOP
  4430. ----------
  4431. This function is used to page the sysop at the local console.
  4432.  
  4433. PAGE_GURU
  4434. ---------
  4435. This function initiates chat with the guru who's internal codes is in the
  4436. current command string. Example (using SMARTGUY as the internal code):
  4437.  
  4438.     SETSTR "SMARTGUY"
  4439.         PAGE_GURU
  4440.  
  4441. PRIVATE_CHAT
  4442. ------------
  4443. This function is used to initiate private node-to-node chat.
  4444.  
  4445. PRIVATE_MESSAGE
  4446. ---------------
  4447. This function is used for private internode messages, telegrams, or chat.
  4448. Same as the Ctrl-P initiated function.
  4449.  
  4450. CHAT_SECTION
  4451. ------------
  4452. This function takes the user immediately to the chat menu where they can
  4453. join multinode chat and perform various other chat related operations.
  4454.  
  4455.  
  4456.  
  4457.  
  4458.  
  4459.  
  4460.  
  4461.  
  4462.  
  4463.  
  4464.  
  4465.  
  4466.  
  4467.  
  4468.  
  4469.  
  4470.  
  4471.  
  4472.  
  4473.  
  4474.  
  4475.  
  4476.  
  4477.  
  4478.  
  4479. _______________________________________________________________________________
  4480. Synchronet                           76                          Chat Functions
  4481.  
  4482.  
  4483. Information Functions
  4484. =====================
  4485.  
  4486. INFO_SYSTEM
  4487. -----------
  4488. This function displays various system information.
  4489.  
  4490. INFO_SUBBOARD
  4491. -------------
  4492. This function displays information about the current message sub-board.
  4493.  
  4494. INFO_DIRECTORY
  4495. --------------
  4496. This function displays information about the current file directory.
  4497.  
  4498. INFO_USER
  4499. ---------
  4500. This function displays information about the current user.
  4501.  
  4502. INFO_VERSION
  4503. ------------
  4504. This function displays version information about the system software.
  4505.  
  4506. INFO_XFER_POLICY
  4507. ----------------
  4508. This function displays the system's transfer policy.
  4509.  
  4510. GURU_LOG
  4511. --------
  4512. This function displays the GURU.LOG file from the DATA directory and prompts
  4513. the user if they wish to delete the log. This is normally reserved as a
  4514. "sysop only" operation.
  4515.  
  4516. ERROR_LOG
  4517. ---------
  4518. This function displays the ERROR.LOG file from the DATA directory and prompts
  4519. the user if they wish to delete the log and/or clear the error counters for
  4520. the nodes. This is normally reserved as a "sysop only" operation.
  4521.  
  4522.  
  4523.  
  4524.  
  4525.  
  4526.  
  4527.  
  4528.  
  4529.  
  4530.  
  4531.  
  4532.  
  4533.  
  4534.  
  4535.  
  4536.  
  4537.  
  4538. _______________________________________________________________________________
  4539. Synchronet                           77                   Information Functions
  4540.  
  4541.  
  4542. SYSTEM_LOG
  4543. ----------
  4544. This function displays the system's detailed activity log for the current date.
  4545. This is normally reserved as a "sysop only" operation.
  4546.  
  4547. SYSTEM_YLOG
  4548. -----------
  4549. This function displays the system's detailed activity log for the previous day.
  4550. This is normally reserved as a "sysop only" operation.
  4551.  
  4552. SYSTEM_STATS
  4553. ------------
  4554. This function displays cumulative system usage statistics.
  4555. This is normally reserved as a "sysop only" operation.
  4556.  
  4557. NODE_STATS
  4558. ----------
  4559. This function displays cumulative usage statistics for the current node.
  4560. This is normally reserved as a "sysop only" operation.
  4561.  
  4562. SHOW_MEM
  4563. --------
  4564. This function displays the amount of free memory available.
  4565. This is normally reserved as a "sysop only" operation.
  4566.  
  4567.  
  4568.  
  4569.  
  4570.  
  4571.  
  4572.  
  4573.  
  4574.  
  4575.  
  4576.  
  4577.  
  4578.  
  4579.  
  4580.  
  4581.  
  4582.  
  4583.  
  4584.  
  4585.  
  4586.  
  4587.  
  4588.  
  4589.  
  4590.  
  4591.  
  4592.  
  4593.  
  4594.  
  4595.  
  4596.  
  4597. _______________________________________________________________________________
  4598. Synchronet                           78                   Information Functions
  4599.  
  4600.  
  4601. File I/O Functions
  4602. ==================
  4603.  
  4604. These functions allow Baja modules to read (input) from and write (ouput) to
  4605. disk files. If any of the following functions fail, the current logic state
  4606. will be set to FALSE and the system variable _ERRNO will contain the reason
  4607. for the failure. All file I/O functions require SBBS v2.2 or later.
  4608.  
  4609. FOPEN <int_var> <#>    <"str" or str_var>                      FILE_IO.INC
  4610.  args: handle     access  path_and_filename
  4611. ------------------------------------------
  4612. This function opens or creates a disk file (path_and_filename) for read and/or
  4613. write access. This function is the Baja equivalent of the standard C fopen()
  4614. function. No file I/O operations can be performed on a file until it has been
  4615. opened with this function. The 'handle' argument must be a defined integer
  4616. variable name. The 'access' argument is the requested open access. The access
  4617. flags (defined in FILE_IO.INC) are:
  4618.  
  4619. Access Flag    Description
  4620. ~~~~~~~~~~~    ~~~~~~~~~~~
  4621. O_RDONLY    Read Only
  4622. O_WRONLY    Write Only
  4623. O_RDWR        Read and write
  4624. O_CREAT     Create      (create if doesn't exist)
  4625. O_APPEND    Append      (writes to end of file)
  4626. O_TRUNC     Truncate  (truncates file to 0 bytes automatically)
  4627. O_EXCL        Exclusive (only open/create if file doesn't exist)
  4628. O_DENYNONE    Deny None (shareble, for use with record locking)
  4629.  
  4630. To specify multiple access flags, place an OR symbol (|) between each. Example:
  4631.  
  4632.     O_WRONLY|O_TRUNC
  4633.  
  4634. If the file does not exist it will be created if the O_CREAT access was
  4635. specified. If the O_CREAT and O_EXCL access flags are set then the open will
  4636. fail if the file already exists.
  4637.  
  4638. Example:
  4639.  
  4640.     !INCLUDE FILE_IO.INC
  4641.  
  4642.         INT file
  4643.     FOPEN file O_RDWR|O_CREAT "%jFILENAME.EXT"
  4644.  
  4645. Would open the file FILENAME.EXT in the BBS data directory (%j is the
  4646. Synchronet command line % specifier for the data directory) for reading and
  4647. writing, creating it if it didn't already exist. All later accesses to the file
  4648. must use the same integer variable ("file" in the above example). If the open
  4649. is successful, the current logic state is set to TRUE, otherwise it is set to
  4650. FALSE.
  4651.  
  4652.  
  4653.  
  4654.  
  4655.  
  4656. _______________________________________________________________________________
  4657. Synchronet                           79                      File I/O Functions
  4658.  
  4659.  
  4660. FCLOSE <int_var>
  4661.   args: handle
  4662. ----------------
  4663. All files opened with the FOPEN function remain open until either this function
  4664. (FCLOSE) is used to close the file (using the same unmodified 'handle') or the
  4665. current shell or module is terminated. This function is the Baja equivalent
  4666. of the standard C fclose() function. A maximum of 10 files can be concurrently
  4667. opened by a shell or module at any given time.
  4668.  
  4669. FREAD <int_var> <any_var> [int_var or #]
  4670.  args: handle     dest       length
  4671. ----------------------------------------
  4672. This function is used to read from a disk file (specified by 'handle') into a
  4673. string or integer variable (specified by 'dest') from the current file
  4674. position. This function is the Baja equivalent of the standard C fread()
  4675. function.
  4676.  
  4677. The optional 'length' argument specifies the number of bytes to read. It must
  4678. be between 1 and 4 if the dest argument is an integer variable and between 1
  4679. and 1024 if the dest argument is a string variable. If 'length' is not
  4680. specified, then 4 bytes is assumed for integer variables or the current string
  4681. length for string variables (or 128 if an uninitialized or 0 length string
  4682. variable is specified). The current file position will be automatically moved
  4683. forward by the number of bytes successfully read from the file.
  4684.  
  4685. If the FSET_ETX function has been used to set the end-of-text character to
  4686. something other than 0 and the dest argument is a string variable, the string
  4687. will be terminated at the first end-of-text character read from the file from
  4688. the current position.
  4689.  
  4690. It is suggested that a 'length' argument always be specified for string
  4691. variable destinations, though it is not usually necessary for integer variable
  4692. destinations.
  4693.  
  4694. FWRITE <int_var> <any_var> [int_var or #]
  4695.   args: handle      source    length
  4696. -----------------------------------------
  4697. This function is used to write an integer or string variable ('source') to a
  4698. disk file ('handle') at the current file position. This function is the Baja
  4699. equivalent of the standard C fwrite() function. If the optional 'length'
  4700. argument is specified, it will determine the number of bytes written to the
  4701. file. If 'source' is a string variable and the number of bytes to be written
  4702. exceeds the string length, the current end-of-text character will be used to
  4703. fill the extra bytes. If 'length' is not specified, 4 bytes will be used for
  4704. integer 'source' variables and the current string length will be used for
  4705. string 'source' variables. The current file position will be automatically
  4706. moved forward by the number of bytes successfully written to the file.
  4707.  
  4708. FFLUSH <int_var>
  4709.   args: handle
  4710. ----------------
  4711. This function forces any pending writes to the disk file ('handle'). All files
  4712. opened by Baja modules use buffered I/O for performance. Closing an open file
  4713. flushes any pending output as well. You may wish to use this function in
  4714.  
  4715. _______________________________________________________________________________
  4716. Synchronet                           80                      File I/O Functions
  4717.  
  4718.  
  4719. multinode applications where it is important that other nodes have immediate
  4720. access to the data written to a file while it is still open. This function is
  4721. the Baja equivalent of the standard C fflush() function. [SBBS 2.3]
  4722.  
  4723.  
  4724.  
  4725.  
  4726.  
  4727.  
  4728.  
  4729.  
  4730.  
  4731.  
  4732.  
  4733.  
  4734.  
  4735.  
  4736.  
  4737.  
  4738.  
  4739.  
  4740.  
  4741.  
  4742.  
  4743.  
  4744.  
  4745.  
  4746.  
  4747.  
  4748.  
  4749.  
  4750.  
  4751.  
  4752.  
  4753.  
  4754.  
  4755.  
  4756.  
  4757.  
  4758.  
  4759.  
  4760.  
  4761.  
  4762.  
  4763.  
  4764.  
  4765.  
  4766.  
  4767.  
  4768.  
  4769.  
  4770.  
  4771.  
  4772.  
  4773.  
  4774. _______________________________________________________________________________
  4775. Synchronet                           81                      File I/O Functions
  4776.  
  4777.  
  4778. FGET_LENGTH <int_var> <int_var>
  4779.        args: handle    length
  4780. -------------------------------
  4781. This function gets the current length (in bytes) of the file pointed to by
  4782. 'handle', and writes the value to the integer variable 'length'. This function
  4783. is the Baja equivalent of the standard C filelength() function.
  4784.  
  4785. FSET_LENGTH <int_var> <int_var>
  4786.        args: handle    length
  4787. -------------------------------
  4788. This function changes the length of the file pointed to by 'handle' to the
  4789. value contained in the integer variable 'length'. If the file is shortened,
  4790. any bytes beyond the specified length are lost. If the file is extended, the
  4791. unused bytes will be automatically padded with 0. This function is the Baja
  4792. equivalent of the standard C chsize() function.
  4793.  
  4794. FGET_TIME <int_var> <int_var>
  4795.      args: handle    time
  4796. -----------------------------
  4797. This function gets the current date/time stamp of the file pointed to by
  4798. 'handle' and writes this value into the 'time' variable. This function is
  4799. the Baja equivalent of the standard C getftime() function.
  4800.  
  4801. FSET_TIME <int_var> <int_var>
  4802.      args: handle    time
  4803. -----------------------------
  4804. This function sets the current date/time stamp of the file pointed to by
  4805. 'handle' to the value contained in the 'time' variable. This function is the
  4806. Baja equivalent of the standard C setftime() function.
  4807.  
  4808. FEOF <int_var>
  4809. args: handle
  4810. --------------
  4811. This function checks the file specified by 'handle' to see if the current
  4812. file position is at the end of the file. If it is currently at the end of the
  4813. file, the current logic state is set to TRUE. If it is not at the end of the
  4814. file or the file 'handle' is not currently open, the logic state is set to
  4815. FALSE. This function is the Baja equivalent of the standard C feof() function.
  4816.  
  4817. FGET_POS <int_var> <int_var>
  4818.     args: handle    offset
  4819. ----------------------------
  4820. This function gets the current file position (in bytes from the beginning of
  4821. the file) for the file specified by 'handle' and writes the value into the
  4822. integer variable 'offset'. This function is the Baja equivalent of the
  4823. standard C ftell() function.
  4824.  
  4825.  
  4826.  
  4827.  
  4828.  
  4829.  
  4830.  
  4831.  
  4832.  
  4833. _______________________________________________________________________________
  4834. Synchronet                           82                      File I/O Functions
  4835.  
  4836.  
  4837. FSET_POS <int_var> <int_var or #> [#]                FILE_IO.INC
  4838.     args: handle    offset       whence
  4839. -----------------------------------------
  4840. This function is used to reposition (seek) within the file specified by
  4841. 'handle' to the offset specified by 'offset' from 'whence', if specified.
  4842. If 'whence' is not specified the 'offset' will be considered from the beginning
  4843. of the file. This function is the Baja equivalent of the standard C fseek()
  4844. function. The valid values of whence (defined in FILE_IO.INC) are:
  4845.  
  4846. Whence        Description
  4847. ~~~~~~        ~~~~~~~~~~~
  4848. SEEK_SET    From the beginning of the file
  4849. SEEK_CUR    From current file position
  4850. SEEK_END    From end of file
  4851.  
  4852. The 'offset' (not offspring) variable can be either an integer variable or
  4853. an integer constant. It may be negative (to move the file position backwards),
  4854. positive (forwards), or 0 (to specify no offset from 'whence').
  4855.  
  4856. Example:
  4857.  
  4858.     !INCLUDE FILE_IO.INC
  4859.  
  4860.         # Open file
  4861.         INT file
  4862.     FOPEN file O_RDWR|O_CREAT "TEXT.TXT"
  4863.         IF_FALSE
  4864.                 # Failed!
  4865.                 RETURN
  4866.                 END_IF
  4867.  
  4868.         # Go to end of file
  4869.     FSET_POS file 0 SEEK_END
  4870.  
  4871.         # Go to beginning of file
  4872.         FSET_POS file 0
  4873.  
  4874.         # Go to offset 256 in file
  4875.         FSET_POS file 256
  4876.  
  4877.         # Seek forward 100 bytes
  4878.     FSET_POS file 100 SEEK_CUR
  4879.  
  4880.         # Seek backward 50 bytes
  4881.     FSET_POS file -50 SEEK_CUR
  4882.  
  4883.         FCLOSE file
  4884.  
  4885.  
  4886.  
  4887.  
  4888.  
  4889.  
  4890.  
  4891.  
  4892. _______________________________________________________________________________
  4893. Synchronet                           83                      File I/O Functions
  4894.  
  4895.  
  4896. FLOCK <int_var> <int_var or #>
  4897.  args: handle     length
  4898. ------------------------------
  4899. This function is used to lock a file record of 'length' bytes from the
  4900. current file position of the file pointed to by 'handle'. If the record cannot
  4901. after 10 retries (one second apart), the current logic state will be set to
  4902. FALSE. All records that are locked should be subsequently unlocked before the
  4903. file is closed or any user interaction or lengthy processing is begun. This
  4904. function is the Baja equivalent of the C locking(int,LK_LOCK,long) function.
  4905.  
  4906. FUNLOCK <int_var> <int_var or #>
  4907.    args: handle    length
  4908. --------------------------------
  4909. This function is used to unlock a file record previously locked by the
  4910. current module. The current file position of 'handle' must be the start of
  4911. the record and the 'length' must be the same length as originally specified
  4912. to the FLOCK function. This function is the Baja equivalent of the C
  4913. locking(int,LK_UNLCK,long) function.
  4914.  
  4915.  
  4916.  
  4917.  
  4918.  
  4919.  
  4920.  
  4921.  
  4922.  
  4923.  
  4924.  
  4925.  
  4926.  
  4927.  
  4928.  
  4929.  
  4930.  
  4931.  
  4932.  
  4933.  
  4934.  
  4935.  
  4936.  
  4937.  
  4938.  
  4939.  
  4940.  
  4941.  
  4942.  
  4943.  
  4944.  
  4945.  
  4946.  
  4947.  
  4948.  
  4949.  
  4950.  
  4951. _______________________________________________________________________________
  4952. Synchronet                           84                      File I/O Functions
  4953.  
  4954.  
  4955. FPRINTF <int_var> <"cstr"> [any_var] [...]
  4956.    args: handle    format  variables
  4957. ------------------------------------------
  4958. This function is very similar to the PRINTF and SPRINTF functions. The
  4959. exception is that the output of the formatted string is written to the current
  4960. file position of the file specified by 'handle'. This function is the
  4961. Baja equivalent of the standard C fprintf() function.
  4962.  
  4963. Example:
  4964.         # Variables
  4965.     INT file length time
  4966.         # Open for append
  4967.     FOPEN file O_WRONLY|O_CREAT|O_APPEND "TEXT.TXT"
  4968.         IF_FALSE
  4969.                 # Failed!
  4970.                 RETURN
  4971.                 END_IF
  4972.  
  4973.         FGET_LENGTH file length
  4974.         FGET_TIME file time
  4975.         TIME_STR str time
  4976.     FPRINTF file "Length: %ld   Time: %s\r\n" length str
  4977.         FCLOSE file
  4978.  
  4979. FREAD_LINE <int_var> <any_var>
  4980.       args: handle    dest
  4981. ------------------------------
  4982. Reads a single line from the open file specified by 'handle' into the
  4983. destination variable specified by 'dest'. If the destination variable is
  4984. a string variable, the terminating carriage return and line feed (if present
  4985. in the file) will be included in the string variable. You can use the
  4986. TRUNCSP function to remove them if needed.
  4987.  
  4988. If the read is successful, the current logic state is set to TRUE, otherwise
  4989. it is set to FALSE. This function is the Baja equivalent of the standard C
  4990. fgets() function.
  4991.  
  4992. FSET_ETX <#>
  4993.     args: etx
  4994. -------------
  4995. This function is used to set the end-of-text character for the current
  4996. shell or module. The default end-of-text character is 0. It is used by the
  4997. FREAD and FWRITE functions to pad/terminate string variables when read from
  4998. and writing to disk files. The 'etx' argument must be a number from 0 to 255.
  4999. Many of Synchronet's data files (USER.DAT, for example) use 3 (appears as
  5000. ^C or a heart) for an end-of-text character. If you intend to read or write
  5001. from any files that use a non-zero end-of-text character, you'll want to use
  5002. this function before using FREAD or FWRITE.
  5003.  
  5004.  
  5005.  
  5006.  
  5007.  
  5008.  
  5009.  
  5010. _______________________________________________________________________________
  5011. Synchronet                           85                      File I/O Functions
  5012.  
  5013.  
  5014. File System Functions
  5015. =====================
  5016.  
  5017. These functions allow Baja modules to peform operations on unopened files.
  5018.  
  5019. CHKFILE <"str" or str_var>
  5020.    args: path_and_filename
  5021. --------------------------
  5022. This function checks for the existence of the 'path_and_filename' specified.
  5023. The path_and_filename should contain path and possibly drive specifications
  5024. (i.e. CHKFILE C:\MYDIR\MYFILE.TXT). If the file exists the current logic state
  5025. is set to TRUE, otherwise it is set to FALSE.
  5026.  
  5027. REMOVE_FILE <str_var>
  5028.        args: path_and_filename
  5029. ------------------------------
  5030. This function attempts to remove the specified path_and_filename. If the
  5031. removal was successful, the current logic state is set to TRUE, otherwise it
  5032. is set to FALSE. This function is the Baja equivlanet of the standard C
  5033. unlink() and remove() functions.
  5034.  
  5035. RENAME_FILE <str_var> <str_var>
  5036.        args: source    dest
  5037. -------------------------------
  5038. This function attempts to rename the file specified as 'source' to the name
  5039. specified in 'dest'. If a different path is specified for 'dest', the drive
  5040. letter must be the same. If the renaming is successful, the current logic
  5041. state is set to TRUE, otherwise it is set to FALSE. This function is the
  5042. equivalent of the standard C rename() function.
  5043.  
  5044. COPY_FILE <str_var> <str_var>
  5045.      args: source    dest
  5046. -----------------------------
  5047. This function attempts to copy the file specified as 'source' to the path
  5048. AND filename specified in 'dest'. If the copy is successful, the current logic
  5049. state is set to TRUE, otherwise it is set to FALSE.
  5050.  
  5051. MOVE_FILE <str_var> <str_var>
  5052.      args: source    dest
  5053. -----------------------------
  5054. This function attepts to move the file specified as 'source' to the path
  5055. AND filename specified in 'dest'. If the source and dest paths are on the
  5056. same drive, this function is the same as a RENAME_FILE. If the source and
  5057. dest paths are on separate drives, then the this is the same as a COPY_FILE
  5058. with the exception that the source file is automatically deleted. If the
  5059. move is successful, the current logic state is set to TRUE, otherwise it is
  5060. set to FALSE.
  5061.  
  5062. GET_FILE_ATTRIB <int_var> <str_var>                DIR_ATTR.INC
  5063.        args: dest       file
  5064. -----------------------------------
  5065. This function retrieves the directory attributes for the file and writes them
  5066. into the dest variable. This function is the Baja equivalent of the C
  5067. _chmod(char *,0) function.
  5068.  
  5069. _______________________________________________________________________________
  5070. Synchronet                           86                   File System Functions
  5071.  
  5072.  
  5073. SET_FILE_ATTRIB <int_var> <str_var>                DIR_ATTR.INC
  5074.        args: attrib    file
  5075. -----------------------------------
  5076. This function sets the directory attributes for the specified file according
  5077. to the attrib flags. This function is the Baja equivalent of the C
  5078. _chmod(char *,1) function. Valid attrib flags (defined in DIR_ATTR.INC) are:
  5079.  
  5080. Flag        Description
  5081. ~~~~        ~~~~~~~~~~~
  5082. FA_RDONLY    Read Only
  5083. FA_HIDDEN    Hiden
  5084. FA_SYSTEM    System
  5085. FA_LABEL    Volume Label
  5086. FA_DIREC    Directory (or subdirectory)
  5087. FA_ARCH     Archive
  5088.  
  5089. Multiple flags may be specified by ORing the flags together with the OR (|)
  5090. symbol. Example:
  5091.  
  5092.     !INCLUDE DIR_ATTR.INC
  5093.     INT I
  5094.     SETSTR "MYFILE.TXT"
  5095.     SET I FA_HIDDEN|FA_SYSTEM
  5096.     SET_FILE_ATTRIB I STR
  5097.  
  5098. # End of DIR_ATTR.INC
  5099.  
  5100. GET_FILE_TIME <int_var> <str_var>
  5101.      args: dest     file
  5102. ---------------------------------
  5103. Retrieves the current date/time stamp of the specified file and writes it
  5104. into the specified dest variable. If the date/time stamp could not be read
  5105. (file doesn't exist perhaps), the value -1 is written to the dest variable.
  5106.  
  5107. GET_FILE_LENGTH <int_var> <str_var>
  5108.        args: dest       file
  5109. -----------------------------------
  5110. Retrieves the current length of the specified file and writes it into the
  5111. specified dest variable. If the file doesn't exist, the value -1 is written
  5112. to the dest variable.
  5113.  
  5114.  
  5115.  
  5116.  
  5117.  
  5118.  
  5119.  
  5120.  
  5121.  
  5122.  
  5123.  
  5124.  
  5125.  
  5126.  
  5127.  
  5128. _______________________________________________________________________________
  5129. Synchronet                           87                   File System Functions
  5130.  
  5131.  
  5132. Directory System Functions
  5133. ==========================
  5134.  
  5135. These functions allow Baja modules to peform operations on directories and
  5136. subdirectories of the local file system.
  5137.  
  5138. MAKE_DIR <str_var>
  5139.     args: dir
  5140. ------------------
  5141. This function attempts to create the directory specified as dir. If the
  5142. directory is successfully created, the current logic state is set to TRUE,
  5143. otherwise it is set to FALSE and the system variable _ERRNO will contain
  5144. the reason. This function is the Baja equivalent of the standard C mkdir()
  5145. function.
  5146.  
  5147. CHANGE_DIR <str_var>
  5148.       args: dir
  5149. --------------------
  5150. This function attempts to change the current directory to the directory
  5151. specified in dir. Since Synchronet assumes the current directory is the
  5152. current NODE directory at all times, this is a very dangerous function
  5153. and should not be used unless absolutely necessary. If the directory is changed
  5154. successfully, the current logic state is set to TRUE, otherwise it is set to
  5155. FALSE and the system variable _ERRNO will contain the reason. This function
  5156. is the Baja equivalent of the standard C chdir() function.
  5157.  
  5158. REMOVE_DIR <str_var>
  5159.       args: dir
  5160. --------------------
  5161. This function attempts to remove the directory specified as dir. If the
  5162. removal is unnsuccessful (files in the directory, directory doesn't exist,
  5163. etc.) the current logic state will be set to FALSE and the system variable
  5164. _ERRNO will contain the reason. This function is the Baja equivalent of the
  5165. standard C rmdir() function.
  5166.  
  5167. OPEN_DIR <int_var> <str_var>
  5168.     args: handle    dir
  5169. ----------------------------
  5170. This function attempts to open the directory specified as dir (should end
  5171. in a '.'). If the directory is successfully opened, the handle is set to
  5172. the directory handle and the current logic state is set to TRUE, otherwise
  5173. the logic state is set to FALSE. This function is the Baja equivalent of the
  5174. standard C opendir() function.
  5175.  
  5176. READ_DIR <int_var> <str_var>
  5177.     args: handle    filename
  5178. ----------------------------
  5179. This function reads the next file name from the open directory handle and
  5180. puts it into the string variable specified as filename. If the read is
  5181. unsuccesful (no more files in directory) the current logic state is set to
  5182. FALSE and the system variable _ERRNO will contain the reason. This function
  5183. is the Baja equivalent of the standard C readdir() function.
  5184.  
  5185.  
  5186.  
  5187. _______________________________________________________________________________
  5188. Synchronet                           88              Directory System Functions
  5189.  
  5190.  
  5191. REWIND_DIR <int_var>
  5192.       args: handle
  5193. --------------------
  5194. This function rewinds the open directory handle to the first directory entry
  5195. (file name). This function is the Baja equivalent of the standard C rewinddir()
  5196. function.
  5197.  
  5198. CLOSE_DIR <int_var>
  5199.      args: handle
  5200. -------------------
  5201. This function closes a previously opened directory handle. This function is
  5202. the Baja equivalent of the standard C closedir() function.
  5203.  
  5204.  
  5205.  
  5206.  
  5207.  
  5208.  
  5209.  
  5210.  
  5211.  
  5212.  
  5213.  
  5214.  
  5215.  
  5216.  
  5217.  
  5218.  
  5219.  
  5220.  
  5221.  
  5222.  
  5223.  
  5224.  
  5225.  
  5226.  
  5227.  
  5228.  
  5229.  
  5230.  
  5231.  
  5232.  
  5233.  
  5234.  
  5235.  
  5236.  
  5237.  
  5238.  
  5239.  
  5240.  
  5241.  
  5242.  
  5243.  
  5244.  
  5245.  
  5246. _______________________________________________________________________________
  5247. Synchronet                           89              Directory System Functions
  5248.  
  5249.  
  5250. System Variables
  5251. ================
  5252.  
  5253. System variables are global variables that are initialized and/or used by
  5254. Synchronet during operation. They should not be defined in your Baja module.
  5255. You must declare these variables by including (with !INCLUDE) SBBSDEFS.INC
  5256. or by declaring (with !GLOBAL) the individual variable names you wish to use.
  5257.  
  5258. These may be used anywhere a user-defined global variable may be used, with
  5259. the exception that many variables may not be written to (modified directly
  5260. by a shell or module). In some cases, there are specific Baja functions for
  5261. modifying otherwise "unmodifiable" system variables. These "Read Only" system
  5262. variables are indicated here with an asterisk (*).
  5263.  
  5264. String Variables
  5265. ----------------
  5266. _USERON.ALIAS           *Alias/Real Name of user online
  5267. _USERON.NAME           *Real/Company Name of user online
  5268. _USERON.HANDLE           *Chat Handle of user online
  5269. _USERON.COMP           *Computer description for user online
  5270. _USERON.NOTE           *Note for user online
  5271. _USERON.ADDRESS        *Address of user online
  5272. _USERON.LOCATION       *Location of user online
  5273. _USERON.ZIPCODE        *Zip/Postal Code of user online
  5274. _USERON.PASS           *Password of user online
  5275. _USERON.BIRTH           *Birthdate of user online
  5276. _USERON.PHONE           *Phone Number of user online
  5277. _USERON.MODEM           *Modem/Connection description of user online
  5278. _USERON.NETMAIL        *NetMail Forwarding Address for user online
  5279. _USERON.TMPEXT           *Temp File Extension (i.e. ZIP) for user online
  5280. _USERON.COMMENT        *Sysop Comment for user online
  5281. _CONNECTION        Current connection description
  5282. _CAP_FNAME        Capture file name
  5283. _CID            Caller-ID information
  5284. _COMSPEC           *Path to operating system command interpreter
  5285.  
  5286. Integer Variables
  5287. -----------------
  5288. _USERON.NUMBER           *Number of user online
  5289. _USERON.ULS           *Total number of files uploaded by user online
  5290. _USERON.DLS           *Total number of files downloaded by user online
  5291. _USERON.POSTS           *Total number of posts sent by user online
  5292. _USERON.EMAILS           *Total number of e-mails sent by user online
  5293. _USERON.FBACKS           *Total number of feedbacks sent by user online
  5294. _USERON.ETODAY           *Total number of e-mails sent today by user online
  5295. _USERON.PTODAY           *Total number of posts sent today by user online
  5296. _USERON.TIMEON           *Total minutes used (excluding this call) by user online
  5297. _USERON.TEXTRA           *Extra time obtained by uploads during previous calls
  5298. _USERON.LOGONS           *Total number of logons by user online
  5299. _USERON.TTODAY           *Total time used today (previous calls)
  5300. _USERON.TLAST           *Total time used during last call
  5301. _USERON.LTODAY           *Total number of logons today
  5302. _USERON.XEDIT           *External editor used by user online
  5303. _USERON.SHELL           *Command shell used be user online
  5304.  
  5305. _______________________________________________________________________________
  5306. Synchronet                           90                        System Variables
  5307.  
  5308.  
  5309. _USERON.LEVEL           *Security level of user online
  5310. _USERON.SEX           *Sex (gender) of user online
  5311. _USERON.ROWS           *Number of screen lines for user online
  5312. _USERON.PROT           *Default download protocol of user online
  5313. _USERON.LEECH           *Total leech downloads detected for user online
  5314. _USERON.MISC           *Miscellaneous attributes for user online
  5315. _USERON.QWK           *QWK settings for user online
  5316. _USERON.CHAT           *Chat settings for user online
  5317. _USERON.FLAGS1           *Flag set #1 for user online
  5318. _USERON.FLAGS2           *Flag set #2 for user online
  5319. _USERON.FLAGS3           *Flag set #3 for user online
  5320. _USERON.FLAGS4           *Flag set #4 for user online
  5321. _USERON.EXEMPT           *Exemption flags for user online
  5322. _USERON.REST           *Restriction flags for user online
  5323. _USERON.ULB           *Total bytes uploaded by user online
  5324. _USERON.DLB           *Total bytes downloaded by user online
  5325. _USERON.CDT           *Total credits for user online
  5326. _USERON.MIN           *Current minutes in minute bank for user online
  5327. _USERON.FREECDT        *Free credits left today for user online
  5328. _USERON.FIRSTON        *Date/time of first call for user online
  5329. _USERON.LASTON           *Date/time of last call for user online
  5330. _USERON.EXPIRE           *Date/time of expiration for user online
  5331. _USERON.PWMOD           *Date/time of last password modification for user online
  5332. _USERON.NS_TIME        *Date/time of last new-file scan for user online
  5333. _CUR_RATE           *Current DCE rate
  5334. _CUR_CPS           *Estimated CPS rate of current connection
  5335. _DTE_RATE        Current DTE rate
  5336. _LNCNTR         Line counter (for auto-screen pause)
  5337. _TOS            Top-Of-Screen? (1=Yes, 0=No)
  5338. _ROWS            Number of screen rows for current user
  5339. _AUTOTERM        Automatic terminal detection results
  5340. _CONSOLE        Console attributes
  5341. _ANSWERTIME        Time phone was answered
  5342. _LOGONTIME        Time of successful logon
  5343. _NS_TIME        Current new-file scan pointer
  5344. _LAST_NS_TIME        Time of last new-file scan
  5345. _ONLINE         Online? (1=LOCAL, 2=REMOTE, 0=No)
  5346. _SYS_STATUS        System status attributes
  5347. _SYS_MISC        System toggle options (SCFG)
  5348. _SYS_PSNUM        PostLink Site Number (SCFG)
  5349. _SYS_TIMEZONE           *System time zone (in SMB format, SCFG)
  5350. _SYS_PWDAYS           *Days between forced password changes (0=disabled, SCFG)
  5351. _SYS_DELDAYS           *Days to preserve deleted user slots (SCFG)
  5352. _SYS_AUTODEL           *Number of days before deleting inactive users (SCFG)
  5353. _SYS_NODES           *Total configured nodes (SCFG)
  5354. _SYS_EXP_WARN           *Days before expiration to warn user (SCFG)
  5355. _SYS_LASTNODE           *Last displayable node (SCFG)
  5356. _SYS_AUTONODE           *First auto-node (SCFG)
  5357. _NODE_SCRNLEN           *Screen length of this node (0=auto-detect, SCFG)
  5358. _NODE_SCRNBLANK        *Minutes between screen blanks (0=disabled, SCFG)
  5359. _NODE_MISC        Node toggle options (SCFG)
  5360. _NODE_VALUSER           *Number of user to send newuser feedback to (SCFG)
  5361. _NODE_IVT           *Bits determining which time-slice APIs to use (SCFG)
  5362. _NODE_SWAP           *Bits determining which swap types to use (SCFG)
  5363.  
  5364. _______________________________________________________________________________
  5365. Synchronet                           91                        System Variables
  5366.  
  5367.  
  5368. _NODE_MINBPS           *Minimum connect rate allowed for this node (SCFG)
  5369. _NODE_NUM           *Number of this node
  5370. _NEW_LEVEL           *Security level to give new users (SCFG)
  5371. _NEW_FLAGS1        Flag set #1 to give new users (SCFG)
  5372. _NEW_FLAGS2        Flag set #2 to give new users (SCFG)
  5373. _NEW_FLAGS3        Flag set #3 to give new users (SCFG)
  5374. _NEW_FLAGS4        Flag set #4 to give new users (SCFG)
  5375. _NEW_EXEMPT        Exemption flags to give new users (SCFG)
  5376. _NEW_REST        Restriction flags to give new users (SCFG)
  5377. _NEW_CDT        Credits to give new users (SCFG)
  5378. _NEW_MIN        Minutes to give new users (SCFG)
  5379. _NEW_SHELL           *Command shell to default to for new users (SCFG)
  5380. _NEW_MISC        Default settings for new users (SCFG)
  5381. _NEW_EXPIRE           *Automatically set newuser expiration days (SCFG)
  5382. _NEW_PROT           *Default download protocol for new users (SCFG)
  5383. _EXPIRED_LEVEL           *Default security level to give expired users (SCFG)
  5384. _EXPIRED_FLAGS1     Default flag set #1 to give expired users (SCFG)
  5385. _EXPIRED_FLAGS2     Default flag set #2 to give expired users (SCFG)
  5386. _EXPIRED_FLAGS3     Default flag set #3 to give expired users (SCFG)
  5387. _EXPIRED_FLAGS4     Default flag set #4 to give expired users (SCFG)
  5388. _EXPIRED_EXEMPT     Default exemption flags to give expired users (SCFG)
  5389. _EXPIRED_REST        Default restriction flags to give expired users (SCFG)
  5390. _MIN_DSPACE           *Minimum disk space (in k) to allow uploads (SCFG)
  5391. _CDT_MIN_VALUE           *Minutes per 100k of credits (SCFG)
  5392. _CDT_PER_DOLLAR     Credits per dollar conversion rate (SCFG)
  5393. _LEECH_PCT           *Leech detection percentage (0=disabled, SCFG)
  5394. _LEECH_SEC           *Minimum elapsed seconds before leech detection (SCFG)
  5395. _NETMAIL_COST        Credit cost to send FidoNet netmail (SCFG)
  5396. _NETMAIL_MISC           *Toggle options for FidoNet netmail (SCFG)
  5397. _INETMAIL_COST        Credit cost to send Internet netmail (SCFG)
  5398. _INETMAIL_MISC        Toggle options for Internet netmail (SCFG)
  5399. _LOGON_ULB        Total bytes uploaded this call
  5400. _LOGON_DLB        Total bytes downloaded this call
  5401. _LOGON_ULS        Total files uploaded this call
  5402. _LOGON_DLS        Total files downloaded this call
  5403. _LOGON_POSTS        Total posts sent this call
  5404. _LOGON_EMAILS        Total emails sent this call
  5405. _LOGON_FBACKS        Total feedback sent this call
  5406. _POSTS_READ        Total posts read this call
  5407. _LOGFILE           *File handle of currently open NODE.LOG
  5408. _NODEFILE           *File handle of currently open NODE.DAB
  5409. _NODE_EXT           *File handle of currently open NODE.EXB
  5410. _TIMELEFT        Number of seconds left online for current user
  5411. _MAX_MINUTES        Max number of minutes allowed in minute bank (SCFG)
  5412. _MAX_QWKMSGS        Max number of messages allowed per QWK packet (SCFG)
  5413. _UQ            Bits determining which questions to ask newusers (SCFG)
  5414. _ERRORLEVEL           *Error level of most recently executed external program
  5415. _ERRNO               *Current DOS error code (see ERRNO.INC for values)
  5416.  
  5417.  
  5418.  
  5419.  
  5420.  
  5421.  
  5422.  
  5423. _______________________________________________________________________________
  5424. Synchronet                           92                        System Variables
  5425.  
  5426.  
  5427. Quick Function Reference
  5428. ========================
  5429.  
  5430. String Manipulation Functions
  5431. -----------------------------
  5432. STR <str_var> [str_var] [...]
  5433. GLOBAL_STR <str_var> [str_var] [...]
  5434. SET <str_var> <"cstr">
  5435. COPY <str_var> <any_var>
  5436. SWAP <str_var> <any_var>
  5437. STRCAT <str_var> <str_var or "cstr">
  5438. SPRINTF <str_var> <"cstr"> <any_var> [any_var] [...]
  5439. TIME_STR <str_var> <int_var>
  5440. DATE_STR <str_var> <int_var>
  5441. SECOND_STR <str_var> <int_var>
  5442. FTIME_STR <str_var> <"cstr"> <int_var>
  5443. SHIFT_STR [str_var] <#>
  5444. STRIP_CTRL [str_var]
  5445. TRUNCSP [str_var]
  5446. STRUPR [str_var]
  5447. STRLWR [str_var]
  5448. SETSTR <"cstr">
  5449. REPLACE_TEXT <#> <"cstr">
  5450. LOAD_TEXT <"str">
  5451. REVERT_TEXT <# or ALL>
  5452.  
  5453. Integer Manipulation Functions
  5454. ------------------------------
  5455. INT <int_var> [int_var] [...]
  5456. GLOBAL_INT <int_var> [int_var] [...]
  5457. SET <int_var> <#>
  5458. ADD <int_var> <any_var or #>
  5459. SUB <int_var> <any_var or #>
  5460. MUL <int_var> <any_var or #>
  5461. DIV <int_var> <any_var or #>
  5462. MOD <int_var> <any_var or #>
  5463. AND <int_var> <any_var or #>
  5464. OR  <int_var> <any_var or #>
  5465. NOT <int_var> <any_var or #>
  5466. XOR <int_var> <any_var or #>
  5467. COPY <int_var> <any_var>
  5468. SWAP <int_var> <any_var>
  5469. RANDOM <int_var> <#>
  5470. TIME <int_var>
  5471. STRLEN <int_var> <str_var>
  5472. DATE_INT <int_var> <str_var>
  5473. CRC16 <int_var> <str_var>
  5474. CRC32 <int_var> <str_var>
  5475. CHKSUM <int_var> <str_var>
  5476. CHARVAL <int_var> <str_var>
  5477.  
  5478.  
  5479.  
  5480.  
  5481.  
  5482. _______________________________________________________________________________
  5483. Synchronet                           93                Quick Function Reference
  5484.  
  5485.  
  5486. Logic/Control Flow Functions
  5487. ----------------------------
  5488. GOTO <txt>
  5489. CALL <txt>
  5490. RETURN
  5491. SETLOGIC <TRUE or FALSE or GREATER or LESS>
  5492. COMPARE <any_var> <any_var or "cstr" or #>
  5493. IF_TRUE
  5494. IF_EQUAL
  5495. IF_FALSE
  5496. IF_NOT_EQUAL
  5497. IF_GREATER
  5498. IF_GREATER_OR_EQUAL
  5499. IF_LESS
  5500. IF_LESS_OR_EQUAL
  5501. ELSE
  5502. END_IF
  5503. SWITCH <int_var>
  5504. CASE <#>
  5505. DEFAULT
  5506. END_CASE
  5507. END_SWITCH
  5508. CMD_HOME
  5509. CMDKEY <key>
  5510. CMDKEYS <keylist>
  5511. CMDSTR <"cstr">
  5512. END_CMD
  5513. CMD_POP
  5514. COMPARE_KEY <key>
  5515. COMPARE_KEYS <keylist>
  5516. COMPARE_STR <"cstr">
  5517. COMPARE_WORD <"cstr">
  5518. COMPARE_ARS <ars>
  5519. COMPARE_STRN <#> <str_var> <str_var or "cstr">
  5520. COMPARE_SUBSTR <str_var> <str_var or "cstr">
  5521.  
  5522.  
  5523.  
  5524.  
  5525.  
  5526.  
  5527.  
  5528.  
  5529.  
  5530.  
  5531.  
  5532.  
  5533.  
  5534.  
  5535.  
  5536.  
  5537.  
  5538.  
  5539.  
  5540.  
  5541. _______________________________________________________________________________
  5542. Synchronet                           94                Quick Function Reference
  5543.  
  5544.  
  5545. Display Functions
  5546. -----------------
  5547. PRINT <"cstr" or any_var>
  5548. PRINTF <"cstr"> <any_var> [any_var] [...]
  5549. PRINT_LOCAL <"cstr">
  5550. PRINT_REMOTE <"cstr">
  5551. PRINTSTR
  5552. PRINTKEY
  5553. MNEMONICS <"cstr">
  5554. CLS
  5555. CRLF
  5556. PRINTFILE <"str" or str_var> [#]
  5557. PRINTTAIL <str_var> <#> <#>
  5558. PRINTFILE_STR
  5559. PRINTFILE_LOCAL <"str">
  5560. PRINTFILE_REMOTE <"str">
  5561. LIST_TEXT_FILE
  5562. EDIT_TEXT_FILE
  5563. PAUSE
  5564. MENU <"str">
  5565. NODELIST_ALL
  5566. NODELIST_USERS
  5567. USERLIST_SUB
  5568. USERLIST_DIR
  5569. USERLIST_ALL
  5570. USERLIST_LOGONS
  5571. YES_NO <"cstr">
  5572. NO_YES <"cstr">
  5573. READ_SIF <"str">
  5574. SAVELINE
  5575. RESTORELINE
  5576.  
  5577. Input Functions
  5578. ---------------
  5579. INKEY
  5580. GETKEY
  5581. GETKEYE
  5582. GETCMD <"cstr">
  5583. GETSTR [str_var] [#] [#]
  5584. GETLINE [str_var] [#]
  5585. GETSTRUPR [str_var] [#]
  5586. GETNAME [str_var] [#]
  5587. GETFILESPEC
  5588. GETLINES
  5589. GETNUM [any_var] <#>
  5590. GET_TEMPLATE <"str">
  5591. CHKSYSPASS
  5592. CREATE_SIF <"str">
  5593.  
  5594.  
  5595.  
  5596.  
  5597.  
  5598.  
  5599.  
  5600. _______________________________________________________________________________
  5601. Synchronet                           95                Quick Function Reference
  5602.  
  5603.  
  5604. Miscellaneous Functions
  5605. -----------------------
  5606. ONLINE
  5607. OFFLINE
  5608. LOGIN <"cstr">
  5609. LOGON
  5610. LOGOFF
  5611. LOGOFF_FAST
  5612. LOGOUT
  5613. NEWUSER
  5614. SET_MENU_DIR <"str">
  5615. SET_MENU_FILE <"str">
  5616. SYNC
  5617. ASYNC
  5618. RIOSYNC
  5619. PUT_NODE
  5620. PAUSE_RESET
  5621. CLEAR_ABORT
  5622. UNGETKEY
  5623. UNGETSTR
  5624. HANGUP
  5625. EXEC <"str">
  5626. EXEC_INT <"str">
  5627. EXEC_BIN <"str">
  5628. EXEC_XTRN <"str">
  5629. LOG <"cstr">
  5630. LOGSTR
  5631. LOGKEY
  5632. LOGKEY_COMMA
  5633. NODE_STATUS <#>
  5634. NODE_ACTION <#>
  5635. INC_MAIN_CMDS
  5636. INC_FILE_CMDS
  5637. COMPARE_USER_MISC <#>
  5638. COMPARE_USER_CHAT <#>
  5639. COMPARE_USER_QWK  <#>
  5640. COMPARE_NODE_MISC <#>
  5641. TOGGLE_USER_MISC <#>
  5642. TOGGLE_USER_CHAT <#>
  5643. TOGGLE_USER_QWK  <#>
  5644. TOGGLE_NODE_MISC <#>
  5645. TOGGLE_USER_FLAG <char> <char>
  5646. ADJUST_USER_CREDITS <#>
  5647. ADJUST_USER_MINUTES <#>
  5648. SET_USER_LEVEL <#>
  5649. SET_USER_STRING <#>
  5650. USER_EVENT <#>
  5651. UTO_MESSAGE
  5652. USER_DEFAULTS
  5653. USER_EDIT
  5654. TEXT_FILE_SECTION
  5655. XTRN_EXEC
  5656. XTRN_SECTION
  5657. MINUTE_BANK
  5658.  
  5659. _______________________________________________________________________________
  5660. Synchronet                           96                Quick Function Reference
  5661.  
  5662.  
  5663. CHANGE_USER
  5664. ANSI_CAPTURE
  5665. FINDUSER
  5666. SELECT_SHELL
  5667. SET_SHELL
  5668. SELECT_EDITOR
  5669. SET_EDITOR
  5670. TRASHCAN <"str">
  5671. GETTIMELEFT
  5672. MSWAIT <#>
  5673. SEND_FILE_VIA <char> <"str" or str_var>
  5674. RECEIVE_FILE_VIA <char> <"str" or str_var>
  5675.  
  5676.  
  5677.  
  5678.  
  5679.  
  5680.  
  5681.  
  5682.  
  5683.  
  5684.  
  5685.  
  5686.  
  5687.  
  5688.  
  5689.  
  5690.  
  5691.  
  5692.  
  5693.  
  5694.  
  5695.  
  5696.  
  5697.  
  5698.  
  5699.  
  5700.  
  5701.  
  5702.  
  5703.  
  5704.  
  5705.  
  5706.  
  5707.  
  5708.  
  5709.  
  5710.  
  5711.  
  5712.  
  5713.  
  5714.  
  5715.  
  5716.  
  5717.  
  5718. _______________________________________________________________________________
  5719. Synchronet                           97                Quick Function Reference
  5720.  
  5721.  
  5722. Mail Functions
  5723. --------------
  5724. MAIL_READ
  5725. MAIL_READ_SENT
  5726. MAIL_READ_ALL
  5727. MAIL_SEND
  5728. MAIL_SEND_FILE
  5729. MAIL_SEND_BULK
  5730. MAIL_SEND_FEEDBACK
  5731. MAIL_SEND_NETMAIL
  5732. MAIL_SEND_NETFILE
  5733.  
  5734. Message Base Functions
  5735. ----------------------
  5736. MSG_SET_AREA
  5737. MSG_SET_GROUP
  5738. MSG_SELECT_AREA
  5739. MSG_SHOW_GROUPS
  5740. MSG_SHOW_SUBBOARDS
  5741. MSG_GROUP_UP
  5742. MSG_GROUP_DOWN
  5743. MSG_SUBBOARD_UP
  5744. MSG_SUBBOARD_DOWN
  5745. MSG_GET_SUB_NUM
  5746. MSG_GET_GRP_NUM
  5747. MSG_READ
  5748. MSG_POST
  5749. MSG_QWK
  5750. MSG_PTRS_CFG
  5751. MSG_PTRS_REINIT
  5752. MSG_NEW_SCAN_CFG
  5753. MSG_NEW_SCAN
  5754. MSG_NEW_SCAN_ALL
  5755. MSG_NEW_SCAN_SUB
  5756. MSG_CONT_SCAN
  5757. MSG_CONT_SCAN_ALL
  5758. MSG_BROWSE_SCAN
  5759. MSG_BROWSE_SCAN_ALL
  5760. MSG_FIND_TEXT
  5761. MSG_FIND_TEXT_ALL
  5762. MSG_YOUR_SCAN_CFG
  5763. MSG_YOUR_SCAN
  5764. MSG_YOUR_SCAN_ALL
  5765.  
  5766.  
  5767.  
  5768.  
  5769.  
  5770.  
  5771.  
  5772.  
  5773.  
  5774.  
  5775.  
  5776.  
  5777. _______________________________________________________________________________
  5778. Synchronet                           98                Quick Function Reference
  5779.  
  5780.  
  5781. File Base Functions
  5782. -------------------
  5783. FILE_SET_AREA
  5784. FILE_SET_LIBRARY
  5785. FILE_SELECT_AREA
  5786. FILE_SHOW_LIBRARIES
  5787. FILE_SHOW_DIRECTORIES
  5788. FILE_LIBRARY_UP
  5789. FILE_LIBRARY_DOWN
  5790. FILE_DIRECTORY_UP
  5791. FILE_DIRECTORY_DOWN
  5792. FILE_GET_DIR_NUM
  5793. FILE_GET_LIB_NUM
  5794. FILE_LIST
  5795. FILE_LIST_EXTENDED
  5796. FILE_VIEW
  5797. FILE_UPLOAD
  5798. FILE_UPLOAD_USER
  5799. FILE_UPLOAD_SYSOP
  5800. FILE_DOWNLOAD
  5801. FILE_DOWNLOAD_USER
  5802. FILE_DOWNLOAD_BATCH
  5803. FILE_REMOVE
  5804. FILE_BATCH_ADD
  5805. FILE_BATCH_ADD_LIST
  5806. FILE_BATCH_CLEAR
  5807. FILE_BATCH_SECTION
  5808. FILE_TEMP_SECTION
  5809. FILE_NEW_SCAN
  5810. FILE_NEW_SCAN_ALL
  5811. FILE_FIND_TEXT
  5812. FILE_FIND_TEXT_ALL
  5813. FILE_FIND_NAME
  5814. FILE_FIND_NAME_ALL
  5815. FILE_PTRS_CFG
  5816. FILE_SET_ALT_PATH
  5817. FILE_RESORT_DIRECTORY
  5818. FILE_SEND
  5819. FILE_GET
  5820. FILE_PUT
  5821. FILE_UPLOAD_BULK
  5822. FILE_FIND_OLD
  5823. FILE_FIND_OPEN
  5824. FILE_FIND_OFFLINE
  5825. FILE_FIND_OLD_UPLOADS
  5826.  
  5827.  
  5828.  
  5829.  
  5830.  
  5831.  
  5832.  
  5833.  
  5834.  
  5835.  
  5836. _______________________________________________________________________________
  5837. Synchronet                           99                Quick Function Reference
  5838.  
  5839.  
  5840. Chat Functions
  5841. --------------
  5842. PAGE_SYSOP
  5843. PAGE_GURU
  5844. PRIVATE_CHAT
  5845. PRIVATE_MESSAGE
  5846. CHAT_SECTION
  5847.  
  5848. Information Functions
  5849. ---------------------
  5850. INFO_SYSTEM
  5851. INFO_SUBBOARD
  5852. INFO_DIRECTORY
  5853. INFO_USER
  5854. INFO_VERSION
  5855. INFO_XFER_POLICY
  5856. GURU_LOG
  5857. ERROR_LOG
  5858. SYSTEM_LOG
  5859. SYSTEM_YLOG
  5860. SYSTEM_STATS
  5861. NODE_STATS
  5862. SHOW_MEM
  5863.  
  5864. File I/O Functions
  5865. ------------------
  5866. FOPEN <int_var> <#> <"str" or str_var>
  5867. FCLOSE <int_var>
  5868. FREAD <int_var> <any_var> [int_var or #]
  5869. FWRITE <int_var> <any_var> [int_var or #]
  5870. FFLUSH <int_var>
  5871. FGET_LENGTH <int_var> <int_var>
  5872. FSET_LENGTH <int_var> <int_var or #>
  5873. FGET_TIME <int_var> <int_var>
  5874. FSET_TIME <int_var> <int_var>
  5875. FEOF <int_var>
  5876. FGET_POS <int_var> <int_var>
  5877. FSET_POS <int_var> <int_var or #> [#]
  5878. FLOCK <int_var> <int_var or #>
  5879. FUNLOCK <int_var> <int_var or #>
  5880. FPRINTF <int_var> <"cstr"> [any_var] [...]
  5881. FREAD_LINE <int_var> <any_var>
  5882. FSET_ETX <#>
  5883.  
  5884. File System Functions
  5885. ---------------------
  5886. CHKFILE <"str" or str_var>
  5887. REMOVE_FILE <str_var>
  5888. RENAME_FILE <str_var> <str_var>
  5889. COPY_FILE <str_var> <str_var>
  5890. MOVE_FILE <str_var> <str_var>
  5891. GET_FILE_ATTRIB <int_var> <str_var>
  5892. SET_FILE_ATTRIB <int_var> <str_var>
  5893. GET_FILE_TIME <int_var> <str_var>
  5894.  
  5895. _______________________________________________________________________________
  5896. Synchronet                          100                Quick Function Reference
  5897.  
  5898.  
  5899. GET_FILE_LENGTH <int_var> <str_var>
  5900.  
  5901.  
  5902.  
  5903.  
  5904.  
  5905.  
  5906.  
  5907.  
  5908.  
  5909.  
  5910.  
  5911.  
  5912.  
  5913.  
  5914.  
  5915.  
  5916.  
  5917.  
  5918.  
  5919.  
  5920.  
  5921.  
  5922.  
  5923.  
  5924.  
  5925.  
  5926.  
  5927.  
  5928.  
  5929.  
  5930.  
  5931.  
  5932.  
  5933.  
  5934.  
  5935.  
  5936.  
  5937.  
  5938.  
  5939.  
  5940.  
  5941.  
  5942.  
  5943.  
  5944.  
  5945.  
  5946.  
  5947.  
  5948.  
  5949.  
  5950.  
  5951.  
  5952.  
  5953.  
  5954. _______________________________________________________________________________
  5955. Synchronet                          101                Quick Function Reference
  5956.  
  5957.  
  5958. Directory System Functions
  5959. --------------------------
  5960. MAKE_DIR <str_var>
  5961. CHANGE_DIR <str_var>
  5962. REMOVE_DIR <str_var>
  5963. OPEN_DIR <int_var> <str_var>
  5964. READ_DIR <int_var> <str_var>
  5965. REWIND_DIR <int_var>
  5966. CLOSE_DIR <int_var>
  5967.  
  5968.  
  5969.  
  5970.  
  5971.  
  5972.  
  5973.  
  5974.  
  5975.  
  5976.  
  5977.  
  5978.  
  5979.  
  5980.  
  5981.  
  5982.  
  5983.  
  5984.  
  5985.  
  5986.  
  5987.  
  5988.  
  5989.  
  5990.  
  5991.  
  5992.  
  5993.  
  5994.  
  5995.  
  5996.  
  5997.  
  5998.  
  5999.  
  6000.  
  6001.  
  6002.  
  6003.  
  6004.  
  6005.  
  6006.  
  6007.  
  6008.  
  6009.  
  6010.  
  6011.  
  6012.  
  6013. _______________________________________________________________________________
  6014. Synchronet                          102                Quick Function Reference
  6015.  
  6016.  
  6017. Index
  6018. =====
  6019.  
  6020.  
  6021. .BIN             5, 53
  6022.  
  6023. .INC             4, 14, 21
  6024.  
  6025. .SRC             4, 19, 21
  6026.  
  6027. @-Code           6, 38, 40, 41
  6028.  
  6029. ADJUST_USER_CREDITS  60, 96
  6030.  
  6031. ADJUST_USER_MINUTES  60, 96
  6032.  
  6033. ANSI_CAPTURE     62, 97
  6034.  
  6035. ASYNC            51, 96
  6036.  
  6037. AUTO_MESSAGE     61
  6038.  
  6039. C String         8-10, 12, 21, 24
  6040.  
  6041. CALL             7, 28, 32, 53, 90-92, 94
  6042.  
  6043. CASE             7, 11, 15, 20, 34-37, 45, 73, 90, 94
  6044.  
  6045. CHANGE_DIR       88, 102
  6046.  
  6047. CHANGE_USER      62, 97
  6048.  
  6049. CHARVAL          31, 93
  6050.  
  6051. CHAT_SECTION     76, 100
  6052.  
  6053. CHKFILE          86, 100
  6054.  
  6055. CHKSUM           31, 93
  6056.  
  6057. CHKSYSPASS       48, 95
  6058.  
  6059. CLEAR_ABORT      52, 96
  6060.  
  6061. CLOSE_DIR        89, 102
  6062.  
  6063. CLS              4, 17, 41, 95
  6064.  
  6065. CMDKEY           11-13, 20, 35, 45, 94
  6066.  
  6067. CMDKEYS          20, 36, 94
  6068.  
  6069. CMDSTR           20, 36, 46, 94
  6070.  
  6071. _______________________________________________________________________________
  6072. Synchronet                          103                                   Index
  6073.  
  6074.  
  6075.  
  6076. CMD_HOME         19, 35, 94
  6077.  
  6078. CMD_POP          35, 94
  6079.  
  6080. Command Line     5, 38, 53, 79
  6081.  
  6082. Command Shell    3-6, 14, 53, 61, 90, 92
  6083.  
  6084. COMPARE          4, 17, 20, 32-37, 45, 56-59, 94, 96
  6085.  
  6086. COMPARE_ARS      18, 20, 37, 94
  6087.  
  6088. COMPARE_KEY      4, 17, 35, 45, 94
  6089.  
  6090. COMPARE_KEYS     36, 94
  6091.  
  6092. COMPARE_NODE_MISC  58, 96
  6093.  
  6094. COMPARE_STR      36, 46, 94
  6095.  
  6096. COMPARE_STRN     37, 94
  6097.  
  6098. COMPARE_SUBSTR   37, 94
  6099.  
  6100. COMPARE_USER_CHAT  57, 59, 96
  6101.  
  6102. COMPARE_USER_MISC  18, 56, 58, 96
  6103.  
  6104. COMPARE_USER_QWK  57, 59, 96
  6105.  
  6106. COMPARE_WORD     37, 94
  6107.  
  6108. Compile          5-7, 14-17
  6109.  
  6110. Constant         7, 10, 13-15, 21, 24, 26, 29, 32, 35, 83
  6111.  
  6112. COPY             23, 30, 53, 86, 93, 100
  6113.  
  6114. COPY_FILE        86, 100
  6115.  
  6116. CRC16            31, 93
  6117.  
  6118. CRC32            31, 93
  6119.  
  6120. CREATE_SIF       44, 49, 95
  6121.  
  6122. CRLF             41, 45, 95
  6123.  
  6124. DATE_INT         31, 93
  6125.  
  6126. DATE_STR         24, 93
  6127.  
  6128. DEFAULT          27, 34, 42, 50, 55, 61, 85, 91, 94, 96
  6129.  
  6130. _______________________________________________________________________________
  6131. Synchronet                          104                                   Index
  6132.  
  6133.  
  6134.  
  6135. DIV              30, 93
  6136.  
  6137. EDIT_TEXT_FILE   42, 95
  6138.  
  6139. ELSE             20, 33, 94
  6140.  
  6141. END_CASE         20, 34, 94
  6142.  
  6143. END_CMD          20, 35, 94
  6144.  
  6145. END_IF           4, 17, 20, 33, 37, 43, 47, 58, 71, 83, 85, 94
  6146.  
  6147. END_SWITCH       20, 34, 94
  6148.  
  6149. ERROR_LOG        77, 100
  6150.  
  6151. Example          4-7, 9-28, 30, 34, 37-43, 45-49, 51, 53, 56-60, 65, 71, 76,
  6152.                  79, 83, 85, 87
  6153.  
  6154. EXEC             4-6, 46, 53, 62, 96
  6155.  
  6156. EXEC_BIN         6, 53, 96
  6157.  
  6158. EXEC_INT         53, 96
  6159.  
  6160. EXEC_XTRN        53, 62, 96
  6161.  
  6162. FCLOSE           80, 83, 85, 100
  6163.  
  6164. FEOF             82, 100
  6165.  
  6166. FFLUSH           80, 100
  6167.  
  6168. FGET_LENGTH      82, 85, 100
  6169.  
  6170. FGET_POS         82, 100
  6171.  
  6172. FGET_TIME        82, 85, 100
  6173.  
  6174. FILE_BATCH_ADD   72, 99
  6175.  
  6176. FILE_BATCH_ADD_LIST  72, 99
  6177.  
  6178. FILE_BATCH_CLEAR  72, 99
  6179.  
  6180. FILE_BATCH_SECTION  72, 99
  6181.  
  6182. FILE_DIRECTORY_DOWN  71, 99
  6183.  
  6184. FILE_DIRECTORY_UP  70, 99
  6185.  
  6186. FILE_DOWNLOAD    46, 72, 99
  6187.  
  6188.  
  6189. _______________________________________________________________________________
  6190. Synchronet                          105                                   Index
  6191.  
  6192.  
  6193. FILE_DOWNLOAD_BATCH  72, 99
  6194.  
  6195. FILE_DOWNLOAD_USER  72, 99
  6196.  
  6197. FILE_FIND_NAME   73, 99
  6198.  
  6199. FILE_FIND_NAME_ALL  73, 99
  6200.  
  6201. FILE_FIND_OFFLINE  75, 99
  6202.  
  6203. FILE_FIND_OLD    74, 99
  6204.  
  6205. FILE_FIND_OLD_UPLOADS  75, 99
  6206.  
  6207. FILE_FIND_OPEN   74, 99
  6208.  
  6209. FILE_FIND_TEXT   73, 99
  6210.  
  6211. FILE_FIND_TEXT_ALL  73, 99
  6212.  
  6213. FILE_GET         71, 74, 99
  6214.  
  6215. FILE_GET_DIR_NUM  71, 99
  6216.  
  6217. FILE_GET_LIB_NUM  71, 99
  6218.  
  6219. FILE_LIBRARY_DOWN  70, 99
  6220.  
  6221. FILE_LIBRARY_UP  70, 99
  6222.  
  6223. FILE_LIST        71, 99
  6224.  
  6225. FILE_LIST_EXTENDED  71, 99
  6226.  
  6227. FILE_NEW_SCAN    18, 73, 99
  6228.  
  6229. FILE_NEW_SCAN_ALL  18, 73, 99
  6230.  
  6231. FILE_PTRS_CFG    73-75, 99
  6232.  
  6233. FILE_PUT         74, 99
  6234.  
  6235. FILE_REMOVE      72, 99
  6236.  
  6237. FILE_RESORT_DIRECTORY  74, 99
  6238.  
  6239. FILE_SELECT_AREA  70, 99
  6240.  
  6241. FILE_SEND        74, 99
  6242.  
  6243. FILE_SET_ALT_PATH  73, 99
  6244.  
  6245. FILE_SET_AREA    70, 99
  6246.  
  6247.  
  6248. _______________________________________________________________________________
  6249. Synchronet                          106                                   Index
  6250.  
  6251.  
  6252. FILE_SET_LIBRARY  70, 99
  6253.  
  6254. FILE_SHOW_DIRECTORIES  70, 99
  6255.  
  6256. FILE_SHOW_LIBRARIES  70, 99
  6257.  
  6258. FILE_TEMP_SECTION  73, 99
  6259.  
  6260. FILE_UPLOAD      71, 74, 99
  6261.  
  6262. FILE_UPLOAD_BULK  74, 99
  6263.  
  6264. FILE_UPLOAD_SYSOP  72, 99
  6265.  
  6266. FILE_UPLOAD_USER  71, 99
  6267.  
  6268. FILE_VIEW        71, 99
  6269.  
  6270. FINDUSER         62, 97
  6271.  
  6272. FLOCK            84, 100
  6273.  
  6274. FOPEN            79, 83, 85, 100
  6275.  
  6276. FPRINTF          85, 100
  6277.  
  6278. FREAD            80, 85, 100
  6279.  
  6280. FREAD_LINE       85, 100
  6281.  
  6282. FSET_ETX         80, 85, 100
  6283.  
  6284. FSET_LENGTH      82, 100
  6285.  
  6286. FSET_POS         83, 100
  6287.  
  6288. FSET_TIME        82, 100
  6289.  
  6290. FTIME_STR        26, 93
  6291.  
  6292. FUNLOCK          84, 100
  6293.  
  6294. FWRITE           80, 85, 100
  6295.  
  6296. GETCMD           4, 17, 20, 35, 40, 45, 52, 95
  6297.  
  6298. GETFILESPEC      47, 71, 95
  6299.  
  6300. GETKEY           25, 35, 40, 45, 52, 95
  6301.  
  6302. GETKEYE          45, 95
  6303.  
  6304. GETLINE          46-48, 95
  6305.  
  6306.  
  6307. _______________________________________________________________________________
  6308. Synchronet                          107                                   Index
  6309.  
  6310.  
  6311. GETLINES         47, 95
  6312.  
  6313. GETNAME          47, 65, 95
  6314.  
  6315. GETNUM           47, 95
  6316.  
  6317. GETSTR           35, 40, 46, 52, 74, 95
  6318.  
  6319. GETSTRUPR        46, 95
  6320.  
  6321. GETTIMELEFT      63, 97
  6322.  
  6323. GET_FILE_ATTRIB  86, 100
  6324.  
  6325. GET_FILE_LENGTH  87, 101
  6326.  
  6327. GET_FILE_TIME    87, 100
  6328.  
  6329. GET_TEMPLATE     48, 95
  6330.  
  6331. Global           7, 16, 22, 27, 29, 51, 90, 93
  6332.  
  6333. GLOBAL_INT       16, 29, 93
  6334.  
  6335. GLOBAL_STR       16, 22, 93
  6336.  
  6337. GOTO             4, 7, 17, 32, 35, 94
  6338.  
  6339. GURU_LOG         77, 100
  6340.  
  6341. HANGUP           50, 52, 96
  6342.  
  6343. IF_EQUAL         33, 94
  6344.  
  6345. IF_FALSE         20, 33, 36, 43, 83, 85, 94
  6346.  
  6347. IF_GREATER       33, 94
  6348.  
  6349. IF_GREATER_OR_EQUAL  33, 94
  6350.  
  6351. IF_LESS          33, 94
  6352.  
  6353. IF_LESS_OR_EQUAL  33, 94
  6354.  
  6355. IF_NOT_EQUAL     33, 94
  6356.  
  6357. IF_TRUE          4, 17, 20, 33, 35-37, 43, 47, 58, 71, 94
  6358.  
  6359. INC_FILE_CMDS    55, 96
  6360.  
  6361. INC_MAIN_CMDS    55, 96
  6362.  
  6363. INFO_DIRECTORY   77, 100
  6364.  
  6365.  
  6366. _______________________________________________________________________________
  6367. Synchronet                          108                                   Index
  6368.  
  6369.  
  6370. INFO_SUBBOARD    77, 100
  6371.  
  6372. INFO_SYSTEM      77, 100
  6373.  
  6374. INFO_USER        77, 100
  6375.  
  6376. INFO_VERSION     77, 100
  6377.  
  6378. INFO_XFER_POLICY  77, 100
  6379.  
  6380. INKEY            45, 95
  6381.  
  6382. INT              16, 21, 23-26, 29-31, 34, 40, 53, 79, 82-89, 93, 96, 100-
  6383.                  102
  6384.  
  6385. Label            4, 7, 19, 32, 35, 87
  6386.  
  6387. LIST_TEXT_FILE   42, 95
  6388.  
  6389. LOAD_TEXT        28, 93
  6390.  
  6391. LOG              22, 27-29, 32, 40, 42, 47, 50, 52-54, 58, 77, 96, 100
  6392.  
  6393. Logic            32-37, 43, 45, 47, 56-58, 62, 65-73, 79, 82, 84-86, 88, 94
  6394.  
  6395. LOGIN            3, 6, 50, 96
  6396.  
  6397. LOGKEY           54, 96
  6398.  
  6399. LOGKEY_COMMA     54, 96
  6400.  
  6401. LOGOFF           3, 17, 43, 50, 61, 96
  6402.  
  6403. LOGOFF_FAST      50, 96
  6404.  
  6405. LOGON            3, 5, 43, 50, 54, 56, 61, 68, 90, 92, 95, 96
  6406.  
  6407. LOGOUT           50, 96
  6408.  
  6409. LOGSTR           54, 96
  6410.  
  6411. MAIL_READ        51, 65, 98
  6412.  
  6413. MAIL_READ_ALL    65, 98
  6414.  
  6415. MAIL_READ_SENT   65, 98
  6416.  
  6417. MAIL_SEND        4, 17, 65, 98
  6418.  
  6419. MAIL_SEND_BULK   65, 98
  6420.  
  6421. MAIL_SEND_FEEDBACK  4, 17, 65, 98
  6422.  
  6423. MAIL_SEND_FILE   65, 98
  6424.  
  6425. _______________________________________________________________________________
  6426. Synchronet                          109                                   Index
  6427.  
  6428.  
  6429.  
  6430. MAIL_SEND_NETFILE  66, 98
  6431.  
  6432. MAIL_SEND_NETMAIL  66, 98
  6433.  
  6434. MAKE_DIR         88, 102
  6435.  
  6436. MENU             3, 6, 12, 19, 35, 42, 50, 55, 61, 72, 76, 95, 96
  6437.  
  6438. MINUTE_BANK      62, 96
  6439.  
  6440. MNEMONICS        4, 17, 41, 95
  6441.  
  6442. MOD              30, 93
  6443.  
  6444. Module           3-7, 14, 16, 19, 22, 27, 29, 32, 46, 50, 53, 79, 84-86, 88,
  6445.                  90
  6446.  
  6447. MOVE_FILE        86, 100
  6448.  
  6449. MSG_BROWSE_SCAN  69, 98
  6450.  
  6451. MSG_BROWSE_SCAN_ALL  69, 98
  6452.  
  6453. MSG_CONT_SCAN    69, 98
  6454.  
  6455. MSG_CONT_SCAN_ALL  69, 98
  6456.  
  6457. MSG_FIND_TEXT    69, 98
  6458.  
  6459. MSG_FIND_TEXT_ALL  69, 98
  6460.  
  6461. MSG_GET_GRP_NUM  68, 98
  6462.  
  6463. MSG_GET_SUB_NUM  68, 98
  6464.  
  6465. MSG_GROUP_DOWN   67, 98
  6466.  
  6467. MSG_GROUP_UP     67, 98
  6468.  
  6469. MSG_NEW_SCAN     68, 98
  6470.  
  6471. MSG_NEW_SCAN_ALL  69, 98
  6472.  
  6473. MSG_NEW_SCAN_CFG  68, 98
  6474.  
  6475. MSG_NEW_SCAN_SUB  69, 98
  6476.  
  6477. MSG_POST         68, 98
  6478.  
  6479. MSG_PTRS_CFG     68, 98
  6480.  
  6481. MSG_PTRS_REINIT  68, 98
  6482.  
  6483.  
  6484. _______________________________________________________________________________
  6485. Synchronet                          110                                   Index
  6486.  
  6487.  
  6488. MSG_QWK          68, 98
  6489.  
  6490. MSG_READ         68, 98
  6491.  
  6492. MSG_SELECT_AREA  67, 98
  6493.  
  6494. MSG_SET_AREA     67, 98
  6495.  
  6496. MSG_SET_GROUP    67, 98
  6497.  
  6498. MSG_SHOW_GROUPS  67, 98
  6499.  
  6500. MSG_SHOW_SUBBOARDS  67, 98
  6501.  
  6502. MSG_SUBBOARD_DOWN  68, 98
  6503.  
  6504. MSG_SUBBOARD_UP  68, 98
  6505.  
  6506. MSG_YOUR_SCAN    69, 98
  6507.  
  6508. MSG_YOUR_SCAN_ALL  69, 98
  6509.  
  6510. MSG_YOUR_SCAN_CFG  69, 98
  6511.  
  6512. MSWAIT           63, 97
  6513.  
  6514. MUL              29, 93
  6515.  
  6516. NEWUSER          49, 54, 61, 91, 96
  6517.  
  6518. NODELIST_ALL     43, 95
  6519.  
  6520. NODELIST_USERS   43, 95
  6521.  
  6522. NODE_ACTION      55, 96
  6523.  
  6524. NODE_STATS       78, 100
  6525.  
  6526. NODE_STATUS      54, 96
  6527.  
  6528. NO_YES           43, 95
  6529.  
  6530. OFFLINE          50, 54, 75, 96, 99
  6531.  
  6532. ONLINE           12, 32, 50, 53, 61, 63, 90-92, 96
  6533.  
  6534. OPEN_DIR         88, 102
  6535.  
  6536. PAGE_GURU        76, 100
  6537.  
  6538. PAGE_SYSOP       76, 100
  6539.  
  6540. PAUSE            12, 28, 42, 51, 91, 95, 96
  6541.  
  6542.  
  6543. _______________________________________________________________________________
  6544. Synchronet                          111                                   Index
  6545.  
  6546.  
  6547. PAUSE_RESET      51, 96
  6548.  
  6549. PRINT            4, 17, 20, 23, 25, 34, 37-41, 46, 65, 95
  6550.  
  6551. PRINTF           9, 24-26, 30, 34, 38-40, 85, 95
  6552.  
  6553. PRINTFILE        41, 95
  6554.  
  6555. PRINTFILE_LOCAL  42, 95
  6556.  
  6557. PRINTFILE_REMOTE  42, 95
  6558.  
  6559. PRINTFILE_STR    41, 95
  6560.  
  6561. PRINTKEY         40, 45, 95
  6562.  
  6563. PRINTSTR         40, 95
  6564.  
  6565. PRINTTAIL        41, 95
  6566.  
  6567. PRINT_LOCAL      40, 95
  6568.  
  6569. PRINT_REMOTE     40, 95
  6570.  
  6571. PRIVATE_CHAT     76, 100
  6572.  
  6573. PRIVATE_MESSAGE  76, 100
  6574.  
  6575. PUT_NODE         51, 96
  6576.  
  6577. RANDOM           31, 34, 93
  6578.  
  6579. READ_DIR         88, 102
  6580.  
  6581. READ_SIF         44, 49, 95
  6582.  
  6583. RECEIVE_FILE_VIA  64, 97
  6584.  
  6585. REMOVE_DIR       88, 102
  6586.  
  6587. REMOVE_FILE      86, 100
  6588.  
  6589. RENAME_FILE      86, 100
  6590.  
  6591. REPLACE_TEXT     27, 93
  6592.  
  6593. RESTORELINE      44, 95
  6594.  
  6595. RETURN           9, 12, 32, 35, 41, 45, 50, 83, 85, 94
  6596.  
  6597. REVERT_TEXT      28, 93
  6598.  
  6599. REWIND_DIR       89, 102
  6600.  
  6601.  
  6602. _______________________________________________________________________________
  6603. Synchronet                          112                                   Index
  6604.  
  6605.  
  6606. RIOSYNC          51, 96
  6607.  
  6608. SAVELINE         44, 95
  6609.  
  6610. SECOND_STR       25, 93
  6611.  
  6612. SELECT_EDITOR    63, 97
  6613.  
  6614. SELECT_SHELL     62, 97
  6615.  
  6616. SEND_FILE_VIA    63, 97
  6617.  
  6618. SETLOGIC         32, 94
  6619.  
  6620. SETSTR           4, 17, 22, 26, 36, 40, 49, 74, 76, 87, 93
  6621.  
  6622. SET_EDITOR       63, 97
  6623.  
  6624. SET_FILE_ATTRIB  87, 100
  6625.  
  6626. SET_MENU_DIR     42, 51, 96
  6627.  
  6628. SET_MENU_FILE    42, 51, 96
  6629.  
  6630. SET_SHELL        63, 97
  6631.  
  6632. SET_USER_LEVEL   60, 96
  6633.  
  6634. SET_USER_STRING  61, 96
  6635.  
  6636. SHIFT_STR        26, 46, 93
  6637.  
  6638. SHOW_MEM         78, 100
  6639.  
  6640. Specifier        27, 38, 53, 79
  6641.  
  6642. SPRINTF          21, 23, 85, 93
  6643.  
  6644. STRCAT           24, 93
  6645.  
  6646. STRIP_CTRL       27, 93
  6647.  
  6648. STRLEN           31, 93
  6649.  
  6650. STRLWR           27, 93
  6651.  
  6652. STRUPR           27, 93
  6653.  
  6654. Style            17-21, 45
  6655.  
  6656. SWAP             23, 31, 91, 93
  6657.  
  6658. SWITCH           20, 34, 94
  6659.  
  6660.  
  6661. _______________________________________________________________________________
  6662. Synchronet                          113                                   Index
  6663.  
  6664.  
  6665. SYNC             50, 96
  6666.  
  6667. System Variable  14, 16, 79, 88, 90-92
  6668.  
  6669. SYSTEM_LOG       78, 100
  6670.  
  6671. SYSTEM_STATS     78, 100
  6672.  
  6673. SYSTEM_YLOG      78, 100
  6674.  
  6675. TEXT_FILE_SECTION  62, 96
  6676.  
  6677. TIME             12, 18, 24-26, 31, 57, 63, 73, 80, 82, 85, 87, 90, 93, 100
  6678.  
  6679. TIME_STR         24, 85, 93
  6680.  
  6681. TOGGLE_NODE_MISC  59, 96
  6682.  
  6683. TOGGLE_USER_CHAT  59, 96
  6684.  
  6685. TOGGLE_USER_FLAG  59, 96
  6686.  
  6687. TOGGLE_USER_MISC  58, 96
  6688.  
  6689. TOGGLE_USER_QWK  59, 96
  6690.  
  6691. TRASHCAN         63, 97
  6692.  
  6693. TRUNCSP          27, 85, 93
  6694.  
  6695. UNGETKEY         52, 96
  6696.  
  6697. UNGETSTR         52, 96
  6698.  
  6699. USERLIST_ALL     43, 95
  6700.  
  6701. USERLIST_DIR     43, 95
  6702.  
  6703. USERLIST_LOGONS  43, 95
  6704.  
  6705. USERLIST_SUB     43, 95
  6706.  
  6707. USER_DEFAULTS    61, 96
  6708.  
  6709. USER_EDIT        62, 96
  6710.  
  6711. USER_EVENT       61, 96
  6712.  
  6713. XOR              10, 30, 93
  6714.  
  6715. XTRN_EXEC        46, 62, 96
  6716.  
  6717. XTRN_SECTION     62, 96
  6718.  
  6719.  
  6720. _______________________________________________________________________________
  6721. Synchronet                          114                                   Index
  6722.  
  6723.  
  6724. YES_NO           18, 43, 95
  6725.  
  6726.  
  6727.  
  6728.  
  6729.  
  6730.  
  6731.  
  6732.  
  6733.  
  6734.  
  6735.  
  6736.  
  6737.  
  6738.  
  6739.  
  6740.  
  6741.  
  6742.  
  6743.  
  6744.  
  6745.  
  6746.  
  6747.  
  6748.  
  6749.  
  6750.  
  6751.  
  6752.  
  6753.  
  6754.  
  6755.  
  6756.  
  6757.  
  6758.  
  6759.  
  6760.  
  6761.  
  6762.  
  6763.  
  6764.  
  6765.  
  6766.  
  6767.  
  6768.  
  6769.  
  6770.  
  6771.  
  6772.  
  6773.  
  6774.  
  6775.  
  6776.  
  6777.  
  6778.  
  6779. _______________________________________________________________________________
  6780. Synchronet                          115                                   Index
  6781.  
  6782.  
  6783.