JOYTemplate for Footer group ” ÿÿh�ÇX�O¶k…òI”z ¶kÐ pÐhlÂìŠI” Y÷%Á³Ðz ¶kZ-–K¥Òi´Z-–K¸ Nä"Õ¦I…` ¶{x„ R< Nä"Õ¦I…` ¶{x„ R#<Lï$ЦI”z ¶yx ULï$ЦI”z ¶xx ULï$ЦI”z ¶x ULï$ЦI”z ¶~x ULï$ЦI”z ¶}x ULï$ЦI”z ¶|x ULï$ЦI”z ¶sx ULï$ЦI”z ¶rx UModern €+¶¹+Yº²‚»»»»»"»›Ù¼»»KºÛº¹¼»í»[XÛ¹šš™:†Ñ©ª©˜Úº˜R¹½j–’¹‰ˆ¹™Ë}×[Y™qË«‹Ë»»»»ÝÝÝÝÝ"wD“d›9›r›£¹9š9ºšÌÜ»­îÛ›‰Ì·š›®Y–g»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»»Í»»»´Úº™»«Û»¨‰‰ˆ©š¨¸™™»—‹˜¸‰ëÉ«¬�»Û»»ºº½œÊ˜‰¸Ù©©½™Û«ÛÙ˜Œ€ x€Script 1: 0x„ R< È�˜ �Spreadsheetx€ x€Script 1: 0x„ R< È &KPage===å :(c)copyright1989byGeoffBuckeridgeð€ x€Script 1: 0x„ R< È@˜ èSpreadsheet(cont)x€ x€Script 1: 0x„ R< È &KPage===å :(c)copyright1989byGeoffBuckeridge �€ x€Script 1: 0x„ R# ÈÀ”Introduction   H1ThisspreadsheetiswritteninMallardBasic.Despitethisadmissionitdoes  ±šrunsurprisinglyfastandisamazinglypowerful.Thereareoneortwo  [0limitations.Firstlythespreadsheetwillnotexceedthesizeofthescreen. (Thatis25cellsdownand10cellsacross.ThehorizontalnumberofcellscanËbeadjusted.   .Theslightsluggishness,mustbeexpectedduetothelanguageitiswrittenin.  |eThislimitation,ishowever,greatlyoffsetbythemanyadvantagestobe  R;gainedfromit.Itsformulacalculatingpower,forinstance,isonlypossible¯becauseitiswrittenininterpretedbasic.   Fewsmallbasicspreadsheetswouldbecapableofhandlingascomplexaformulaasthis:- (c8*months)+((c23/4*weeks)-(17*a12))  'Youcanseethattheformulaisverysimilartothosewhichmightbefoundin  P9anybasicprogram.Andthat'sthebeautyofit.Thisspreadsheetactually  R;writesandrunssmallbasicprograms.SothecomplexityoftheformulaeisIgovernedonlybythelimitationsofbasicitself.  ��€ x€Script 1: 0x„ R# È`”Features   Q&Tosimplifyoperationgreatly,cellreferencesareusedlikec8,c23anda12. …nTheserelatedirectlytothecellsonthe25x10gridwhicharelettered!horizontallyandnumberedvertically.   G0Usefulfeaturesinclude'cutandpaste'toreplicatecellcontents.UptotenÚmemoriesareprovidedforthispurpose.   U>Wildcardscanbeusedinnon-cell-dependantsituations.e.g.!1+!2+!3canbe :#placedincelld4toproducethesumofd1,d2andd3,orthesameformulain pYcellg7willgivethesumofg1,g2andg3.Thisexampleshowsawayof  <%performingcalculationsoncolumns.Thesameapproachcanbeappliedtoline  1calculations.Butthistimethequestionmarkreplacesthecurrentlinenumber.°e.g.a?+b?+c?.   'Oneotherfeatureistheabilitytoacceptstraightforwardbasiccommandsin # anyofthecells.ThisisgoodforincludingIF/THEN/ELSEstatements.You  S<couldevenusesomeofthemoreexoticcommandslikeRND,UPPER$,orPRINTxUSINGwhichallowsyoutotailorthespreadsheettodojobsotherscan't.  �°€ x€Script 1: 0x„ R# È`”Tutorial  Nowletsruntheprogram.ItworksbestifitisrunfromtheMdrive,though  5thatisnotabsolutelynecessary.LoadCP/MandcopyBASIC.COM,SPREAD.BAS¼andany.SSSfilestoM:.LogontoM:andtype:-BASIC SPREAD.  Thedisplaywillstartoffwithanemptyspreadsheet.Noticefirstofallthat |eitiseightcolumnswide,labelleda-h.Tryusingthecursorkeystomove  aroundthescreen.Nowletsloadanexistingspreadsheetbytyping'EXTRA'and¼'R'together,andwhenprompted,thefile-nameACCOUNT.  Afterawhiletheframewillfillfromthetop,startingwithtext,thenaftera D-briefpause,thenumbers.Movethecursortothemonthlyfoodcell,theone P9with100.00init.Press'ENTER'or'RETURN'andtype'140'thebottomline shouldsay'InNumeric#=140'.Hitandafterashortwhileallthenumericgvalueswillberecalculated.Trythisagainusingavalueof400thistime.  7 Next,ensurethereispaperintheprinterandtype'EXTRAP'whichwilldoa …nvirtualscreendump.Installanewsheetofpaperandusethe'EXTRAC'ícommandtodumpallthecellcontentstotheprinter.   Youwillfindthatifyoumovethecursorandpress'EXIT'thecontentsofthat *cellisdisplayedatthebottomofthescreen.Itispossibletoeditthisline  quitesimply,usingnormallineeditcommandswhichwillbefullydescribedlater. U>FornowsticktocursorandDELkeys.Alsousethe[+]totheleftofthe  spacebar,whichswitchesbetweenINSERTandOVERSTRIKEmode.Noticehowthe �`€€ x€Script 1: 0x„ R# È  9firsttwocharactersofthelinechangetoinformyouwhichmodeisengaged.  Alsoinsteadofcursoringfromcelltocell,tryusing'FIND'followedbyaletter´oranumberorbothtomovedirectlytoaspecificcell.  /Studyboththeprintoutofthecellcontentsandthescreenandtryandwork S<outwhatishappening.Thepatternissimple.Ifthelinebeginswitha'#' I2symbol,itiseitheranumericconstant(e.g.cellc10)oraformula(e.g.cell 3g10).Ifitbeginswitha'Š'thenabasiclinefollows.Ontheotherhandif  ¦�neithersymbolispresentitispurelyatextcellwhichisignoredwhen;recalculationoccurs.   Togojustonestepfurther,ifthesecondcharacteronthelineisa'='itis  ²›shorthandfor'thiscellequals'.Forexampleincellf23youcouldput  +'#g23=100'butthiswouldhavethesameeffectasputting'#=100'incellg23. :#Thedifferenceisthatthevalueishidden.Todisplayitgotocellh23,and¡makeit#=g23.  §�Lookatcellsa2andb2whichareabitdifferent.Theyintroducetwo  variables,fredandmary,andassignvaluestothem,equivalenttothesepeoples2monthlysalary.Bothvariablesareagainreferencedincellg8.   �vCellsd10,d12,d20,andd21areexamplesusingthewildcard'?'whichis  automaticallyreplacedwiththecurrentlinenumber.Seehowthesamecommand"readsdifferently,dependingonwhichcellitisin.  �p€ x€Script 1: 0x„ R# È  `ISofarwehaveonlydealtwithnumericcellswhichareinitialisedeitherby aJpressing'ENTER'or'#'.Theothermaintypeisthetextcell.Thisoneis B+easytofillasitisinitialisedbytypinganynon-commandcharacter.Goto Af24andtype'Thequickbrownfox'slowlysothatyoucanwatchthescreen.AYouwillseethateacheachcellisfilledandthenincremented.  K4BeforewefinishwithACCOUNTstudycellsa1andb1.Thesearebothbasic L5typecells.Iwontdiscussthese,indetailbutleaveitforyoutoworkout # whattheyaredoing.Aclueisthatarrayb()referstothenumericcells,and arrayb$()referstothetext.Cellg12isreferencedbyb(12,7)Ifyouwant mVtoenterbasicatacell,press'Š'andtypeyourline.Ifthespreadsheet J3doesn'tlikeitanerrorwilloccur.Theerrornumberisstraightoutofthe•MallardBasicerrorcodelist.  A*Ifyouwanttosavethisspreadsheetjusttype'EXTRAS'butIwouldadvise 9"younottocallitACCOUNTasitwilloverwritethepreviousversion.Asyou zcseeitreturnstothesameplacesoyoucouldcontinue.However,onthis occasionwewillclearthescreenreadyforanothergo.Press'TAB'andanswer thepromptwiththevalueeight.Thiswillgiveyouthesameemptydisplayyou 5startedwith.TryTABagainbutthistimeselect5columns.Thenumberyou 3chooseatthisstagecannotbechangedonceyoustartfillingthecells,asit L5willclearthemagain,sochooseitcarefully.ThisnumberisalsosavedandÍloadedwithyourspreadsheet,ofcourse.   M6Oneortwoothercommandsdeserveaspecialmention.Forinstancethecell  memory.Tostorethecontentsofacellpress'EXIT'togointoeditmodethen �`€€ x€Script 1: 0x„ R# È B'COPY'thenanynumber0-9.Thiswillcopythiscelltooneoftenmemories. M6Torecallitpress'PASTE'thenthesamenumber,whileyourcursurisintheñframe.Thememorycanbeusedonanytypeofcell.  P9Anothercommandofnoteis[-],totheleftofthespacebar,whichtoggles T=autocellincrementon/off.Withitoffthecursorreturnstothesamecell (afterentry.Toggledon,thecursormovestothenextcellontheright,readyIforthenextentry.   Ithinkthataboutcoversmostofthecommands.Therestwillbedealtwithin  tIthecommandsummary.Allthelineeditingcommandsarealsolistedthere. 2BeforemovingonloadupandstudyEXPENSESinthesamewayaswedidwithACCOUNT.   %Ihopeyouarebeginningtounderstandtheintricaciesoftheprogramandcan v_anticipatesomeusesofyourown.Itreallyisquitefuntousewhenyoubecomefamiliarwithit. �ð€ x€Script 1: 0x„ R# ÈX”CellCommandSummary.  RCAN #¼Erasescurrentcell. òCURSORKEYS #¼Tomovefromcelltocell [-] #¼Automovetonextcell,toggleon/off. ©# #¼Numericleader. ÌŠ #¼Basicleader. =ENTER #¼ThesameasRETURN. €EXIT #¼Editcurrentcell. °EXTRAC #¼Doesaprinterlistingofthecellcontents. ªEXTRAP #¼Printsavirtualscreendump. EXTRAR #¼Recallfile.Againyouareaskedfora. #¼filename.Beepsifitdoesn'texist. ¨EXTRAS #¼Savefile.Youarepromptedforafilename. xFIND #¼Godirectlytoaparticularcell. ²PASTE #¼Pastesoneoftenmemoriesatcurrentcell #¼position. áRELAY #¼Runsbasiconlycommands. FRETURN #¼Enternumericconstantorformula. gSTOP #¼ExitsSpreadsheetbacktobasic. 3TAB #¼Setsthehorizontalnumberofcells. �H€ x€Script 1: 0x„ R# Èh”LineEditorCommandSummary  wCAN #¼Exitslineeditignoringchanges. æCOPY #¼Copiesthiscelltooneoftenmemories. {CURSORLEFT/RIGHT #¼Movesthecursorleftorrightonecharacter. ‹CUT #¼Deletestotheendoftheline. )<-DEL #¼Deletescharactertoleftofcursor. 4DEL-> #¼Deletescharacterunderthecursor. =ENTER #¼ThesameasRETURN. ±FIND #¼Togglescursorbetweenendoflineandthe9 #¼beginningoftheline. åRETURN #¼Terminateslineeditmode. ¥[+] #¼Togglesbetweeninsertandoverstrikemode.