.. L------------!---!----!-------------------------------------------------------!--!----------------------------------R .mt 2 .mb 3 .pl66 ** RA ** .pc60 ** RA ** .pn5 ** RA ** .po 8 .he MBASIà COMMANDS¬ STATEMENTÓ ANÄ FUNCTIONS COMMAND EXPLANATION FORMAT POS Returnó thå positioî oæ thå cursoò oî thå line® Thå lefthanä columî ió numbeò 1. POÓ PRINT Displayó ] ¿ [] PRINÔ £ Printó datá tï á sequentiaì filå OPENeä aó "O"® PRINÔ #¬ PRINT USING Outputó formatteä datá tï thå screeî (PRINT© oò tï á sequentiaì filå OPENeä aó "O¢ (PRINÔ #). PRINÔ £ USINÇ PRINÔ USINÇ "";              £ Onå peò digiô positioî (includinç -¬ iæ needed).               Substitutionó foò #:               . Decimaì  poinô position®  Thå numbeò ió arrangeä correctlù arounä it®  Iæ neeä be¬  thå  lasô                       printeä decimaì placå ió rounded. , Onå commá iî anù positioî putó á commá everù threå digitó iî thå integeò parô oæ thå number. ** Printó anù leadinç blankó aó *. $$ Putó á dollaò sigî iî froî oæ thå firsô "non-blank¢ digit. Additions: ^ Á  trailinç Þ giveó exponentiaì form¬  usinç ´ columnó morå thaî defineä bù ##®  Positioî  thå                       decimaì poinô carefully. + - Alwayó printeä iæ specified® Maù bå leadinç oò trailing. String fields: & Variable-lengtè strinç field® Anù spacinç beforå thå nexô fielä ió iî additioî tï thå lengtè oæ thå                  string¬ noô parô oæ it. \ \ Fixed-lengtè strinç field® Thå \Ü arå parô oæ thå field-length¬ i.e® "Ü \¢ ió foò á four-characteò                  field¬  noô á two-characteò one® Onlù spaceó arå alloweä betweeî thå \\® \Ü giveó á two-characteò                  field¬ hence: ¡ Singlå characteò strinç field® !¡ ió twï fields. Literals: _ Ensureó thaô thå nexô characteò ió treateä aó ó literaì (e.g®  _###.#£ printó "#10.32"¬ foò á field-                  lengtè oæ 5¬ noô 6). Alì otheò characteró arå treateä aó literals¬ anä arå printeä "aó seen". PUT Writeó  á  recorä tï á randoí accesó filå froí itó buffer¬  wherå iô waó inserteä witè PRINT#¬  PRINÔ  £              USINÇ oò WRITE£ statement® Seå alsï GET® PUÔ [#]] RANDOMIZE Seedó  thå randoí numbeò generator®  Iæ ] READ Transferó  valueó  froí DATÁ statementó tï variables®  Alì DATÁ anä REAÄ statementó musô agreå iî  typå              (strinç oò numeric)¬ oò therå wilì bå á "Typå mismatch¢ error® Iæ therå arå morå READó thaî DATÁ items¬              aî "Ouô oæ data¢ erroò occurs® "Extra¢ DATÁ itemó arå ignored® Uså RESTORÅ tï re-REAÄ DATÁ items. REAÄ REM Alì  characteró tï thå righô oæ REÍ arå ignored®  Á REÍ linå caî bå thå targeô oæ á GOTÏ oò GOSUB®  Aî              apostrophå  ('©  maù bå substituteä foò "REM"¬  anä maù alsï bå useä tï inserô remarkó aô thå enä  oæ  á              line® REÍ RENUM Sequentiallù  renumberó prograí lines®  Linå referencå (e.g®  GOSUB© arå changeä tï agreå witè thå  ne÷              numbering®  Á  barå RENUÍ wilì renumbeò thå wholå prograí froí 10¬  incrementinç bù 10®  Thå ® Thå incremenô remainó 10® ,®  Tï changå thå increment¬  alì threå optionó musô bå used® Linå              numberó cannoô bå changeä ouô oæ sequence¬ anä á linå numbeò cannoô bå greateò thaî 65529. RENUÍ [[][¬ ][¬ ]]] .pa ŠCOMMAND EXPLANATION FORMAT RESEÔ Closeó alì opeî fileó anä updateó thå disã filå directory® Uså beforå changinç discó withiî á program. RESET RESTORE Resetó thå DATÁ pointeò foò REAÄ tï eitheò thå firsô DATÁ statement¬  oò tï thå DATÁ statemenô aô  ® RESTORÅ [] RESUME Resumå  executioî  oæ thå prograí afteò aî erroò routine®  Thå ° optioî RESUMEó aô thå linå  wherå  thå              erroò occured» NEXÔ aô thå linå after» anä ] RETURN Returnó prograí executioî tï thå linå afteò thå mosô recenô GOSU executed®  Therå caî bå morå thaî onå              RETURÎ iî á subroutine¬  e.g®  IÆ ¬  witè anotheò RETURÎ aô thå enä oæ              thå subroutine® RETURN RIGHT$ Returnó thå right-mosô ® Iæ ¬              alì oæ ¬ ) RND Returnó á randoí numbeò betweeî ° anä 1¬  iî á sequencå baseä oî thå currenô seed® Iæ )] RSET Right-justifieó strinç datá iî á variable® Therå arå twï useó foò thió statement: (1) Tï  puô datá intï thå buffeò oæ á randoí accesó file®  Á strinç thaô ió toï lonç foò thå  fielä  ió                  truncateä froí thå right® Numberó musô bå converteä tï string¬ usinç MK*$. (2) Tï right-justifù á unsubscripteä strinç expressioî intï á strinç variable. RSEÔ RUN Executeó á program®  RUÎ runó thå prograí iî memory®  Thå ]["[d:]"[,R]] SAVE Saveó  thå  prograí iî memorù tï disã aó .BAS¬  over-writinç  anù  existinç  .BAS®  Usuallù              programó arå SAVEä iî binarù format¬  buô thå ,Á optioî saveó iô aó aî ASCIÉ file»  whilsô ,Ð doeó sï iî              "protected¢ formaô (unlistable¬ uneditable)® SAVÅ "[d:]"[,AÝ [,P] SGÎ Returnó ± iæ ) SIÎ Returnó thå (singlå prec.© sinå oæ ) SPACES¤ Returnó ) SPà Outputó ) SQR Returnó thå squarå rooô oæ ¬ whicè musô bå greateò thaî zero. SQÒ () STOP Stopó  executioî oæ á prograí anä returnó tï Commanä leveì iî MBASIC¬  witè thå messagå "Breaë  iî  linå              nnn"® Thå prograí caî bå restarteä witè CONT® STOÐ caî gï anywherå iî thå program. STOP STR¤ Returnó thå strinç representatioî oæ ® STR¤ () STRING¤ Returnó á string¬ © oò ® STRING¤ ¬ | SWAP Exchangeó  thå valueó oæ ¬  whicè musô bå oæ thå samå typå (string¬  singlå  precision¬              etc.)® SWAÐ ¬ SYSTEM Returnó tï thå CP/Í commanä level¬  afteò closinç alì opeî fileó anä updatinç thå disã directory® ^à ió              alreadù useä tï breaë ouô oæ runninç programs® SYSTEM TAB Positionó  thå  cursoò tï columî ®  Iæ thå cursoò ió alreadù pasô ¬  iô ió  moveä  tï              columî ) TAN Returnó thå tangenô oæ ) TRON TROFF Turnó thå "trace¢ oî oò off®  Wheî On¬  thå numbeò oæ thå linå beinç executeä ió printeä oî thå  screeî              withiî []® TROÎ TROFF USÒ Calló aî assemblù languagå subroutine¬ identifieä bù ® Ý () .pa ŠCOMMAND“ EXPLANATION“ FORMAT VAL Convertó á strinç representatioî oæ á numbeò intï á reaì number® Thå "opposite¢ oæ STR$()® Equivalenô              tï á numeriã keyboarä inpuô tï INPUT® VAÌ () VARPTR Returnó  thå  starô addresó oæ ¬  oò thå I/Ï buffeò oæ #®  Anù variablå typå maù  bå              checked® Iæ thå addresó returneä ió negative¬ adä 65536® VARPTR(© ü #() WAIT  Suspendó  prograí executioî untiì ó statuó ió á specifieä biô pattern®  Thå porô numbeò ió  XOR'ä              witè J¬  theî ANDeä witè I® Defaulô foò Ê ió 1® Thå porô ió repeatedlù reaä untiì thå resulô ió noô 0®              Aî infinitå looð ½ reseô thå computer® WAIÔ ¬ I[J] WHILE...WEND Performó á conditionaì looð WHILÅ WRITE # Outputó  datá  tï á sequentiaì filå ¬  whicè haó beeî OPENeä aó "O"®  Thå expressionó iî  ¬ .. L-----!----!---------------------------!---!------------------------------------------------------------------------R MBASIC_ERROR_CODES Codeº /° BÓ CÎ DÄ Fà IÄ LÓ NÆ OÄ OÍ OÓ OÖ RÇ SÎ TÍ SÔ UÆ UL Noº 1± ¹ 1· 1° µ 1² 1µ ± ´ · 1´ ¶ ³ ² 1³ 1¶ 1¸ 8 CODE NO. MESSAGE MEANING NÆ ± NEXÔ Withouô FOÒ Nï FOÒ witè thå samå variablå namå aó thió NEXT. SN 2 Syntax Error Yoõ can'ô typå properly®  Looë foò misspellings¬ unmatcheä bracketó anä wronç                                        punctuation. RÇ ³ RETURÎ Withouô GOSU Toï manù RETURNÓ foò noô enougè GOSUBS® Checë ho÷ theù match. OÄ ´ Ouô oæ Datá Á REAÄ statemenô haó ruî ouô oæ DATA® Ho÷ manù timeó doeó thaô looð operate? FC 5 Illegal Function Call Parameteò tï thaô functioî ió ouô oæ range®  Iæ usinç á variable¬ mug-trað iô                                        first® Maù be:                                            Negativå oò too-largå subscript                                            Negativå mantissá witè á non-integeò exponent                                            LOGº Negativå oò zerï argument                                            SQRº Negativå argument                                            USRº Calleä beforå startinç addresó haó beeî given                                            INP¬  INSTR¬  LEFT$¬  MID$¬  ON..GOTO¬ OUT¬  PEEK¬ POKE¬ RIGHT$¬ TAB¬ SPC¬                                            STRING$¬ SPACE$¬ WAITº Incorrecô argument. OV 6 Overflow Thå  numbeò  ió  toï  biç foò thå variablå iô ió tï gï  iî  (e.g®  aî  integeò                                        variablå caî onlù holä numberó betweeî -3276¸ anä +32767). N.B® Underflo÷ (toï smalì á number© ió jusô treateä aó zero¬ withouô aî erroò beinç reported. OM 7 Out of Memory Prograí  toï large»  toï manù FOÒ loopó oò GOSUBs»  oò useä toï complicateä aî                                        expression. UL 8 Undefined Line Thå  linå  yoõ havå trieä tï GOTO¬  GOSUB¬  IF..THEN..ELSÅ oò DELETÅ doeó  noô                                        exist. BS 9 Subscript Out of Range Arraù  accesó  witè eitheò á subscripô toï largå foò thå arraù  size¬  oò  thå                                        wronç numbeò oæ subscripts. DD 10 Redimensioned Array Eitheò morå thaî onå DIÍ foò aî array¬  oò thå DIÍ ió afteò thå arraù haó beeî                                        used. /0 11 Division by Zero Eitheò divisioî bù zerï (whù didn'ô yoõ mug-trað it?)¬ oò zerï haó beeî raiseä                                        tï á negativå power. IÄ 1² Illegaì Direcô Yoõ can'ô uså thaô aó á "Direcô Mode¢ command. TÍ 1³ Typå Mismatcè Á strinç variablå oò functioî haó beeî giveî á numeriã value¬ oò vicå versa. DS 14 Out of String Space BASIà allocateó strinç spacå dynamicallù untiì iô runó ouô oæ  memory¬  whicè                                        yoõ havå jusô done. LÓ 1µ Strinç Toï Lonç Maximuí lengtè ió 25µ characters. SÔ 1¶ Strinç formulá Toï Compleø Breaë iô uð intï smalleò chunks. CÎ 1· Can'ô Continuå CONTinuå doesn'ô after: Aî erroò iî á runninç program Yoõ havå modifieä thå prograí iî á break Therå ió nï prograí there! UÆ 1¸ Undefineä Useò Functioî Á USÒ functioî ió calleä beforå iô haó beeî DEFined. Š.. L----!-------------------------!---!--------------------------------------------------------------------------------R Extended_and_Disc_BASIC_Errors NO. MESSAGE MEANING 19 No RESUME In an error-trapping routine. 20 RESUME Without Error RESUME not in an error-trap. 21 Unprintable Error Nï erroò messagå foò thió erroò - usuallù aî ERROÒ withouô aî erroò number. 22 Missing Operand Thå operatoò (+-*¯ etc© ió there¬ buô nï operand. 23 Line Buffer Overflow Thå linå ió toï lonç (Maø 25µ characters). 26 FOR Without NEXT No matching NEXT found. 29 WHILE Without WEND No matching WEND found. 30 WEND Without WHILE Vice versa. Disc_Errors NO. MESSAGE MEANING 50 Field Overflow Random file record is too small for that number of characters. 51 Internal Error MicroSoft have a bug! Please tell them all about it. 5² Baä Filå Numbeò Thå filå numbeò ió noô OPEN¬ oò ió ouô oæ rangå specifieä aô initialisation. 53 File Not Found KILL¬ LOAD¬ OPENº Thå filå ió noô oî thaô disc. 5´ Baä Filå Modå GET¬ LOF¬ PUTº Useä witè á sequentiaì file LOADº Á randoí accesó file OPENº Onlù É Ï Ò modeó arå valid 5µ Filå Alreadù Opeî KILLº Yoõ can'ô eraså aî opeî file OPEÎ "O"º It'ó á sequentiaì filå thaô ió alreadù open 57 Disk I/O Error Á fataì erroò (CP/Í cannoô recoveò froí it)® Á disã I/Ï error. 58 File Already Exists NAME: That filename is already in use on that disc. 61 Disk Full It's full. 6² Inpuô Pasô Enä INPUTº Alì thå datá iî thå filå haó beeî INPUT» oò aî emptù file® Uså WHILÅ NOÔ EOF® 63 Bad Record Number GET, PUT: The record number is either zero or more than 32767. 64 Bad File Name KILL, LOAD, OPEN, SAVE: Too many characters in the filename. 6¶ Direcô Statemenô Iî Filå LOADº Á direcô modå statemenô ió iî thå ASCII-formaô file® Thå LOAÄ ió stopped. 6· Toï Manù Fileó OPEN¬ SAVEº Yoõ can'ô havå sï manù files. Noteº Yoõ maù uså erroò numberó betweeî 6¸ anä 25µ foò youò owî purposes.