PMIDBMS.LST 158 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163
  1. Listing:
  2. 1 MODULE PMIdbms; (* * REPERTOIRE * Release 1.6 * By Charles Bradford and
  3. 2 Cole Brecheen * (c) Copyright 1985-1991 PMI * Green Bay Wisconsin * All
  4. 3 rights reserved * (414) 468-6040 * * $Header:
  5. 4 D:/logfiles/demos/pmidbms.mov 1.3 09 Dec 1990 11:18:22 coleb $ * * A
  6. 5 program to illustrate use of REPERTOIRE's screen * and NdxFile system.
  7. 6 This is the advanced example; * programmers new to REPERTOIRE should begin
  8. 7 with DEMO1. *)
  9. 8
  10. 9
  11. 10 (*
  12. 11 IMPORT EMS;
  13. 12 EMS is part of PMI's EmsStorage, a product separate from
  14. 13 Repertoire. It allows Repertoire applications automatically
  15. 14 to use expanded memory. If you don't have it, just comment
  16. 15 out the IMPORT EMS from any program modules in which it
  17. 16 appears.*)
  18. 17
  19. 18 IMPORT BuildLst;
  20. 19 IMPORT ByteFiddler;
  21. 20 IMPORT ControlUtils;
  22. 21 IMPORT DateFunctions;
  23. 22 IMPORT DirManager;
  24. 23 IMPORT Drectory;
  25. 24 IMPORT DspFiles;
  26. 25 IMPORT EnvironUtils;
  27. 26 IMPORT ErrorManager;
  28. 27 IMPORT ErrStrgs;
  29. 28 IMPORT HandleIO;
  30. 29 IMPORT FrameManager;
  31. 30 IMPORT FramePainter;
  32. 31 IMPORT GenLists;
  33. 32 IMPORT InitCompilerMods;
  34. 33 IMPORT InputManager;
  35. 34 IMPORT KbdInput;
  36. 35 IMPORT ListUtils;
  37. 36 IMPORT NdxUtils;
  38. 37 IMPORT MsgBox2;
  39. 38 IMPORT NdxBones;
  40. 39 IMPORT NdxFiles;
  41. 40 IMPORT NdxTypes;
  42. 41 IMPORT NumTypes;
  43. 42 IMPORT PosUtils;
  44. 43 IMPORT PrtFrame;
  45. 44 IMPORT Scrn2Ndx;
  46. 45 IMPORT ScrnTypes;
  47. 46 IMPORT ScrnUtl1;
  48. 47 IMPORT ScrnUtl2;
  49. 48 IMPORT SmartScreen;
  50. 49 IMPORT StrConv;
  51. 50 IMPORT StrEdit;
  52. 51 IMPORT StringIO;
  53. 52 IMPORT M2Strings;
  54. 53 IMPORT UserOps;
  55. 54 IMPORT VEditor;
  56. 55 IMPORT VWindows;
  57. 56 IMPORT WindowPrims;
  58. 57
  59. 58
  60. 59 VAR
  61. 60 NdxFile: NdxTypes.NdxFileType;
  62. ***** ^ not supported yet
  63. 61 ScreenFile: ScrnTypes.DisplayFile;
  64. ***** ^ not supported yet
  65. 62 EntryFrame: ScrnTypes.DisplayFrame;
  66. ***** ^ not supported yet
  67. 63 NdxFileName, RecName: ARRAY [0..79] OF CHAR;
  68. ***** ^ not supported yet
  69. ***** ^ not supported yet
  70. 64 dumbool: BOOLEAN;
  71. 65 PrnHandle, SavedCursorHeight : CARDINAL;
  72. 66
  73. 67
  74. 68 PROCEDURE PrintMenu();
  75. 69 VAR
  76. 70 TmpName: ScrnTypes.AFrameName;
  77. ***** ^ not supported yet
  78. 71 thestr: ARRAY [0..79] OF CHAR;
  79. ***** ^ not supported yet
  80. ***** ^ not supported yet
  81. 72 ff: ARRAY [0..0] OF CHAR;
  82. ***** ^ not supported yet
  83. ***** ^ not supported yet
  84. 73 FormFeeding, dumbool: BOOLEAN;
  85. 74 TmpList: GenLists.GenList;
  86. ***** ^ not supported yet
  87. 75 chkey: CARDINAL;
  88. 76 LeftMargin : INTEGER;
  89. 77 InvoiceFrame, DialogBox: ScrnTypes.DisplayFrame;
  90. ***** ^ not supported yet
  91. 78
  92. 79 PROCEDURE WriteInvoice();
  93. 80 VAR
  94. 81 NewEd: GenLists.GenList;
  95. ***** ^ not supported yet
  96. 82 month, day, year, AcctBalance: CARDINAL;
  97. 83 date, name, tmpstr : ARRAY [0..50] OF CHAR;
  98. ***** ^ not supported yet
  99. ***** ^ not supported yet
  100. 84 BEGIN
  101. 85 ControlUtils.ReadInput( EntryFrame, tmpstr, 'ACCTBAL' );
  102. ***** ^ not supported yet
  103. ***** ^ not supported yet
  104. ***** ^ not supported yet
  105. ***** ^ not supported yet
  106. ***** ^ not supported yet
  107. 86 (* get account balance string from record entry frame *)
  108. 87 IF NOT StrConv.StrToCardinal(tmpstr, 0, AcctBalance) THEN
  109. ***** ^ not supported yet
  110. ***** ^ not supported yet
  111. ***** ^ not supported yet
  112. ***** ^ not supported yet
  113. 88 AcctBalance := 0;
  114. 89 END;
  115. 90 IF AcctBalance > 0 THEN
  116. 91 StrEdit.MakeCurrency( '$', tmpstr );
  117. ***** ^ not supported yet
  118. ***** ^ not supported yet
  119. ***** ^ not supported yet
  120. 92 ControlUtils.ChangeField( InvoiceFrame, tmpstr,
  121. ***** ^ not supported yet
  122. ***** ^ not supported yet
  123. ***** ^ not supported yet
  124. ***** ^ not supported yet
  125. 93 'AMTDUE', TRUE );
  126. ***** ^ not supported yet
  127. ***** ^ not supported yet
  128. 94 ControlUtils.ChangeField( InvoiceFrame, '$0.00',
  129. ***** ^ not supported yet
  130. ***** ^ not supported yet
  131. ***** ^ not supported yet
  132. ***** ^ not supported yet
  133. 95 'AMTPAID', TRUE );
  134. ***** ^ not supported yet
  135. ***** ^ not supported yet
  136. 96 ELSE
  137. 97 ControlUtils.ChangeField( InvoiceFrame, 'prepaid',
  138. ***** ^ not supported yet
  139. ***** ^ not supported yet
  140. ***** ^ not supported yet
  141. ***** ^ not supported yet
  142. 98 'TERMS', TRUE );
  143. ***** ^ not supported yet
  144. ***** ^ not supported yet
  145. 99 END;
  146. 100 EnvironUtils.GetDate( month, day, year, name, date );
  147. ***** ^ not supported yet
  148. ***** ^ not supported yet
  149. ***** ^ not supported yet
  150. ***** ^ not supported yet
  151. 101 (* get the system date *)
  152. 102 ControlUtils.ChangeField( InvoiceFrame, date, 'DATE', TRUE );
  153. ***** ^ not supported yet
  154. ***** ^ not supported yet
  155. ***** ^ not supported yet
  156. ***** ^ not supported yet
  157. ***** ^ not supported yet
  158. ***** ^ not supported yet
  159. 103 (*Insert the current date.*)
  160. 104 ControlUtils.ChangeField( InvoiceFrame, date, 'SHIPDATE', TRUE);
  161. ***** ^ not supported yet
  162. ***** ^ not supported yet
  163. ***** ^ not supported yet
  164. ***** ^ not supported yet
  165. ***** ^ not supported yet
  166. ***** ^ not supported yet
  167. 105 (* fill in default dates *)
  168. 106 ControlUtils.ReadInput( EntryFrame, name, 'NAME');
  169. ***** ^ not supported yet
  170. ***** ^ not supported yet
  171. ***** ^ not supported yet
  172. ***** ^ not supported yet
  173. ***** ^ not supported yet
  174. 107 (* get the name of the customer out of the record entry frame*)
  175. 108 ScrnUtl2.CopyEdField( EntryFrame, 'ADDRESS',
  176. ***** ^ not supported yet
  177. ***** ^ not supported yet
  178. ***** ^ not supported yet
  179. ***** ^ not supported yet
  180. 109 InvoiceFrame, 'SOLDTO');
  181. ***** ^ not supported yet
  182. ***** ^ not supported yet
  183. 110 ScrnUtl2.GetEdField( InvoiceFrame, 'SOLDTO', NewEd );
  184. ***** ^ not supported yet
  185. ***** ^ not supported yet
  186. ***** ^ not supported yet
  187. ***** ^ not supported yet
  188. ***** ^ not supported yet
  189. 111 GenLists.ListInsert( name, GenLists.StrCode, NewEd, 1);
  190. ***** ^ not supported yet
  191. ***** ^ not supported yet
  192. ***** ^ not supported yet
  193. ***** ^ not supported yet
  194. ***** ^ not supported yet
  195. ***** ^ not supported yet
  196. ***** ^ not supported yet
  197. 112 (* put name and address in sold to field; notice that
  198. 113 we don't have to do a PutEdField here because
  199. 114 ScrnUtl2.GetEdField returns the real list, not a copy of it. *)
  200. 115 ScrnUtl2.CopyEdField( InvoiceFrame, 'SOLDTO', InvoiceFrame,
  201. ***** ^ not supported yet
  202. ***** ^ not supported yet
  203. ***** ^ not supported yet
  204. ***** ^ not supported yet
  205. ***** ^ not supported yet
  206. 116 'SHIPTO');
  207. ***** ^ not supported yet
  208. 117 FramePainter.ShowDisplayFrame( InvoiceFrame, 0, 0, 0, 0 );
  209. ***** ^ not supported yet
  210. ***** ^ not supported yet
  211. ***** ^ not supported yet
  212. ***** ^ not supported yet
  213. 118 InputManager.ControlFrame( InvoiceFrame, 0, '', FALSE, TmpName );
  214. ***** ^ not supported yet
  215. ***** ^ not supported yet
  216. ***** ^ not supported yet
  217. ***** ^ not supported yet
  218. 119 (* now let user change screen if desired *)
  219. 120 IF NOT PosUtils.Equal( TmpName, InvoiceFrame^.normlnext ) THEN
  220. ***** ^ not supported yet
  221. ***** ^ not supported yet
  222. ***** ^ not supported yet
  223. ***** ^ not supported yet
  224. ***** ^ not supported yet
  225. 121 RETURN
  226. 122 END;
  227. 123 IF AcctBalance > 0 THEN
  228. 124 PrtFrame.PrintDisplayFrame( InvoiceFrame,
  229. ***** ^ not supported yet
  230. ***** ^ not supported yet
  231. ***** ^ not supported yet
  232. 125 PrnHandle, LeftMargin );
  233. ***** ^ not supported yet
  234. 126 StringIO.WriteStr( PrnHandle, 14C);
  235. ***** ^ not supported yet
  236. ***** ^ not supported yet
  237. ***** ^ not supported yet
  238. 127 (* send a page feed to the printer *)
  239. 128 END;
  240. 129 ControlUtils.ChangeField( InvoiceFrame,
  241. ***** ^ not supported yet
  242. ***** ^ not supported yet
  243. ***** ^ not supported yet
  244. 130 ' This Copy For Your Records.', 'TITLE', FALSE );
  245. ***** ^ not supported yet
  246. ***** ^ not supported yet
  247. ***** ^ not supported yet
  248. 131 PrtFrame.PrintDisplayFrame( InvoiceFrame,
  249. ***** ^ not supported yet
  250. ***** ^ not supported yet
  251. ***** ^ not supported yet
  252. 132 PrnHandle, LeftMargin );
  253. ***** ^ not supported yet
  254. 133 END WriteInvoice;
  255. ***** ^ not supported yet
  256. 134
  257. 135 BEGIN
  258. 136 (*PrintMenu*)
  259. 137 ScrnTypes.InitDisplayFrame( DialogBox, VWindows.CurrentWindow );
  260. ***** ^ not supported yet
  261. ***** ^ not supported yet
  262. ***** ^ not supported yet
  263. ***** ^ not supported yet
  264. ***** ^ not supported yet
  265. 138 ScrnTypes.InitDisplayFrame( InvoiceFrame, VWindows.CurrentWindow );
  266. ***** ^ not supported yet
  267. ***** ^ not supported yet
  268. ***** ^ not supported yet
  269. ***** ^ not supported yet
  270. ***** ^ not supported yet
  271. 139 DspFiles.ReadDisplayFrame( ScreenFile, InvoiceFrame, '28' );
  272. ***** ^ not supported yet
  273. ***** ^ not supported yet
  274. ***** ^ not supported yet
  275. ***** ^ not supported yet
  276. ***** ^ not supported yet
  277. 140 (* now fill screen with input data *)
  278. 141 PrnHandle := StringIO.StdPrn;
  279. ***** ^ not supported yet
  280. ***** ^ not supported yet
  281. 142 ff[0] := CHR(12);
  282. ***** ^ not supported yet
  283. ***** ^ not supported yet
  284. ***** ^ undeclared identifier
  285. ***** ^ not supported yet
  286. 143 LOOP
  287. 144 TmpName := 'PrintDialog'; (*The print menu screen.*)
  288. ***** ^ not supported yet
  289. ***** ^ not supported yet
  290. 145 ControlUtils.ReadShowAndCntrl( ScreenFile, DialogBox, TmpName );
  291. ***** ^ not supported yet
  292. ***** ^ not supported yet
  293. ***** ^ not supported yet
  294. ***** ^ not supported yet
  295. ***** ^ not supported yet
  296. 146 IF PosUtils.Equal( TmpName, '5' ) THEN
  297. ***** ^ not supported yet
  298. ***** ^ not supported yet
  299. ***** ^ not supported yet
  300. ***** ^ not supported yet
  301. 147 (* User pressed Cancel or Escape *)
  302. 148 EXIT;
  303. 149 END;
  304. 150 chkey := ScrnUtl1.WhichChoiceKey( DialogBox,
  305. ***** ^ not supported yet
  306. ***** ^ not supported yet
  307. ***** ^ not supported yet
  308. 151 ScrnUtl1.FieldNum(DialogBox, 'file') );
  309. ***** ^ not supported yet
  310. ***** ^ not supported yet
  311. ***** ^ not supported yet
  312. ***** ^ not supported yet
  313. 152 CASE CHR(chkey) OF
  314. ***** ^ undeclared identifier
  315. ***** ^ not supported yet
  316. 153 'f':
  317. 154 HandleIO.OpenForAppending( "PRINTER.TXT", PrnHandle);
  318. ***** ^ not supported yet
  319. ***** ^ not supported yet
  320. ***** ^ not supported yet
  321. ***** ^ not supported yet
  322. 155 | 'p':
  323. 156 StringIO.PrintMessage(HandleIO.OpenFile(PrnHandle,'PRN'));
  324. ***** ^ not supported yet
  325. ***** ^ not supported yet
  326. ***** ^ not supported yet
  327. ***** ^ not supported yet
  328. ***** ^ not supported yet
  329. 157 END;
  330. 158 FormFeeding := ScrnUtl1.WhichChoiceKey( DialogBox,
  331. ***** ^ not supported yet
  332. ***** ^ not supported yet
  333. ***** ^ not supported yet
  334. 159 ScrnUtl1.FieldNum(DialogBox, 'ff') ) = ORD('Y');
  335. ***** ^ not supported yet
  336. ***** ^ not supported yet
  337. ***** ^ not supported yet
  338. ***** ^ not supported yet
  339. ***** ^ undeclared identifier
  340. ***** ^ not supported yet
  341. 160 ScrnUtl1.GetIntField( DialogBox,
  342. ***** ^ not supported yet
  343. ***** ^ not supported yet
  344. ***** ^ not supported yet
  345. 161 ScrnUtl1.FieldNum(DialogBox, 'margin'), LeftMargin );
  346. ***** ^ not supported yet
  347. ***** ^ not supported yet
  348. ***** ^ not supported yet
  349. ***** ^ not supported yet
  350. ***** ^ not supported yet
  351. 162 chkey := ScrnUtl1.WhichChoiceKey( DialogBox,
  352. ***** ^ not supported yet
  353. ***** ^ not supported yet
  354. ***** ^ not supported yet
  355. 163 ScrnUtl1.FieldNum(DialogBox, 'label') );
  356. ***** ^ not supported yet
  357. ***** ^ not supported yet
  358. ***** ^ not supported yet
  359. ***** ^ not supported yet
  360. 164 CASE CHR(chkey) OF
  361. ***** ^ undeclared identifier
  362. ***** ^ not supported yet
  363. 165 'A':
  364. 166 ControlUtils.ReadInput( EntryFrame, thestr, 'NAME');
  365. ***** ^ not supported yet
  366. ***** ^ not supported yet
  367. ***** ^ not supported yet
  368. ***** ^ not supported yet
  369. ***** ^ not supported yet
  370. 167 StringIO.PrintMessage( HandleIO.FillFile( PrnHandle,
  371. ***** ^ not supported yet
  372. ***** ^ not supported yet
  373. ***** ^ not supported yet
  374. ***** ^ not supported yet
  375. 168 LeftMargin, ' ' ) );
  376. ***** ^ not supported yet
  377. 169 StrEdit.CrunchBlanks(thestr);
  378. ***** ^ not supported yet
  379. ***** ^ not supported yet
  380. ***** ^ not supported yet
  381. 170 StringIO.WriteEol( PrnHandle, thestr );
  382. ***** ^ not supported yet
  383. ***** ^ not supported yet
  384. ***** ^ not supported yet
  385. 171 IF NOT ScrnUtl1.ListFromEdField(
  386. ***** ^ not supported yet
  387. ***** ^ not supported yet
  388. 172 EntryFrame,
  389. ***** ^ not supported yet
  390. 173 ScrnUtl1.FieldNum( EntryFrame, 'ADDRESS' ),
  391. ***** ^ not supported yet
  392. ***** ^ not supported yet
  393. ***** ^ not supported yet
  394. ***** ^ not supported yet
  395. 174 TmpList ) THEN
  396. ***** ^ not supported yet
  397. 175 HALT();
  398. ***** ^ undeclared identifier
  399. ***** ^ not supported yet
  400. 176 END;
  401. 177 ListUtils.PrintList( PrnHandle, TmpList, LeftMargin,
  402. ***** ^ not supported yet
  403. ***** ^ not supported yet
  404. ***** ^ not supported yet
  405. 178 StringIO.CrLf );
  406. ***** ^ not supported yet
  407. ***** ^ not supported yet
  408. 179 | 'I':
  409. 180 WriteInvoice();
  410. ***** ^ not supported yet
  411. ***** ^ not supported yet
  412. 181 | 'T':
  413. 182 PrtFrame.PrintFrameData( EntryFrame, PrnHandle, LeftMargin );
  414. ***** ^ not supported yet
  415. ***** ^ not supported yet
  416. ***** ^ not supported yet
  417. ***** ^ not supported yet
  418. 183 END;
  419. 184 IF FormFeeding THEN
  420. 185 StringIO.WriteEol( PrnHandle, ff );
  421. ***** ^ not supported yet
  422. ***** ^ not supported yet
  423. ***** ^ not supported yet
  424. 186 END;
  425. 187 END;
  426. 188 StringIO.PrintMessage( HandleIO.CloseHandle( PrnHandle));
  427. ***** ^ not supported yet
  428. ***** ^ not supported yet
  429. ***** ^ not supported yet
  430. ***** ^ not supported yet
  431. ***** ^ not supported yet
  432. 189 ScrnUtl2.CloseDisplayFrame( InvoiceFrame );
  433. ***** ^ not supported yet
  434. ***** ^ not supported yet
  435. ***** ^ not supported yet
  436. 190 ScrnUtl2.CloseDisplayFrame( DialogBox );
  437. ***** ^ not supported yet
  438. ***** ^ not supported yet
  439. ***** ^ not supported yet
  440. 191 END PrintMenu;
  441. ***** ^ not supported yet
  442. 192
  443. 193
  444. 194 PROCEDURE DoOneRecord( RecName: ARRAY OF CHAR );
  445. ***** ^ not supported yet
  446. 195 VAR
  447. 196 KeyHit, month, day, year: CARDINAL;
  448. 197 DateStr, dumstr: ARRAY [0..15] OF CHAR;
  449. ***** ^ not supported yet
  450. ***** ^ not supported yet
  451. 198 ch: CHAR;
  452. 199 NextName: ScrnTypes.AFrameName;
  453. ***** ^ not supported yet
  454. 200 TmpFrame: ScrnTypes.DisplayFrame;
  455. ***** ^ not supported yet
  456. 201 BEGIN
  457. 202 ScrnTypes.InitDisplayFrame( TmpFrame, VWindows.CurrentWindow );
  458. ***** ^ not supported yet
  459. ***** ^ not supported yet
  460. ***** ^ not supported yet
  461. ***** ^ not supported yet
  462. ***** ^ not supported yet
  463. 203 DspFiles.ReadFrame( ScreenFile, EntryFrame, '3' );
  464. ***** ^ not supported yet
  465. ***** ^ not supported yet
  466. ***** ^ not supported yet
  467. ***** ^ not supported yet
  468. ***** ^ not supported yet
  469. 204 (*Frame 3 is the entry form.*)
  470. 205 IF NOT Scrn2Ndx.FillScrFast( NdxFile, EntryFrame,
  471. ***** ^ not supported yet
  472. ***** ^ not supported yet
  473. ***** ^ not supported yet
  474. ***** ^ not supported yet
  475. 206 RecName, '') THEN
  476. ***** ^ not supported yet
  477. ***** ^ not supported yet
  478. 207 (*FillScr says we're creating a new record, so fill the
  479. 208 screen with some default values to save the user
  480. 209 some typing.*)
  481. 210 ControlUtils.ChangeField( EntryFrame, RecName, 'name', TRUE );
  482. ***** ^ not supported yet
  483. ***** ^ not supported yet
  484. ***** ^ not supported yet
  485. ***** ^ not supported yet
  486. ***** ^ not supported yet
  487. ***** ^ not supported yet
  488. 211 (*Insert the RecName they've selected.*)
  489. 212 EnvironUtils.GetDate( month, day, year, dumstr, DateStr );
  490. ***** ^ not supported yet
  491. ***** ^ not supported yet
  492. ***** ^ not supported yet
  493. ***** ^ not supported yet
  494. 213 ControlUtils.ChangeField( EntryFrame, DateStr, 'date', TRUE );
  495. ***** ^ not supported yet
  496. ***** ^ not supported yet
  497. ***** ^ not supported yet
  498. ***** ^ not supported yet
  499. ***** ^ not supported yet
  500. ***** ^ not supported yet
  501. 214 (*Insert the current date.*)
  502. 215 END;
  503. 216 FramePainter.ShowDisplayFrame( EntryFrame, 0, 0, 0, 0 );
  504. ***** ^ not supported yet
  505. ***** ^ not supported yet
  506. ***** ^ not supported yet
  507. ***** ^ not supported yet
  508. 217 (*Displays the entry form.*)
  509. 218 REPEAT
  510. 219 NextName := '5';
  511. ***** ^ not supported yet
  512. 220 (*The menu at the top of the screen.*)
  513. 221 ControlUtils.ReadShowAndCntrl( ScreenFile, TmpFrame, NextName );
  514. ***** ^ not supported yet
  515. ***** ^ not supported yet
  516. ***** ^ not supported yet
  517. ***** ^ not supported yet
  518. ***** ^ not supported yet
  519. 222 IF PosUtils.Equal( NextName, '2' ) THEN
  520. ***** ^ not supported yet
  521. ***** ^ not supported yet
  522. ***** ^ not supported yet
  523. ***** ^ not supported yet
  524. 223 (* User pressed Escape *)
  525. 224 IF EntryFrame^.FrameChanged THEN
  526. ***** ^ not supported yet
  527. ***** ^ not supported yet
  528. 225 IF MsgBox2.MsgOkay( TmpFrame, VWindows.SE,
  529. ***** ^ not supported yet
  530. ***** ^ not supported yet
  531. ***** ^ not supported yet
  532. ***** ^ not supported yet
  533. ***** ^ not supported yet
  534. 226 "Changes made will be lost. Please confirm." ) THEN
  535. ***** ^ not supported yet
  536. 227 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  537. ***** ^ not supported yet
  538. ***** ^ not supported yet
  539. ***** ^ not supported yet
  540. 228 RETURN;
  541. 229 ELSE
  542. 230 ch := 0C;
  543. 231 NextName := '5';
  544. ***** ^ not supported yet
  545. 232 END;
  546. 233 ELSE
  547. 234 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  548. ***** ^ not supported yet
  549. ***** ^ not supported yet
  550. ***** ^ not supported yet
  551. 235 RETURN;
  552. 236 END;
  553. 237 ELSE
  554. 238 ch := CAP( ScrnUtl1.SelectedChar( TmpFrame ) );
  555. ***** ^ undeclared identifier
  556. ***** ^ not supported yet
  557. ***** ^ not supported yet
  558. ***** ^ not supported yet
  559. 239 END;
  560. 240 IF ch = 'S' THEN
  561. 241 (*Store*)
  562. 242 StrEdit.SetLength( RecName, 0 );
  563. ***** ^ not supported yet
  564. ***** ^ not supported yet
  565. ***** ^ not supported yet
  566. ***** ^ not supported yet
  567. 243 (*We're using a null record name here to make PutScrFast
  568. 244 take its record name from the 'name' field in EntryFrame.*)
  569. 245 EnvironUtils.GetDate( month, day, year, dumstr, DateStr );
  570. ***** ^ not supported yet
  571. ***** ^ not supported yet
  572. ***** ^ not supported yet
  573. ***** ^ not supported yet
  574. 246 ControlUtils.ChangeField( EntryFrame, DateStr, 'date', TRUE );
  575. ***** ^ not supported yet
  576. ***** ^ not supported yet
  577. ***** ^ not supported yet
  578. ***** ^ not supported yet
  579. ***** ^ not supported yet
  580. ***** ^ not supported yet
  581. 247 (*Make the date field reflect date of last change.*)
  582. 248 IF Scrn2Ndx.PutScrFast( NdxFile, EntryFrame,
  583. ***** ^ not supported yet
  584. ***** ^ not supported yet
  585. ***** ^ not supported yet
  586. ***** ^ not supported yet
  587. 249 RecName, 'name') THEN
  588. ***** ^ not supported yet
  589. ***** ^ not supported yet
  590. 250 IF NOT NdxFiles.WriteRecord( NdxFile, RecName) THEN
  591. ***** ^ not supported yet
  592. ***** ^ not supported yet
  593. ***** ^ not supported yet
  594. ***** ^ not supported yet
  595. 251 ControlUtils.RdShwAndCntrlConst( ScreenFile, TmpFrame, '17' );
  596. ***** ^ not supported yet
  597. ***** ^ not supported yet
  598. ***** ^ not supported yet
  599. ***** ^ not supported yet
  600. ***** ^ not supported yet
  601. 252 (*"Cannot put record in file" message*)
  602. 253 ELSE
  603. 254 EntryFrame^.FrameChanged := FALSE;
  604. ***** ^ not supported yet
  605. ***** ^ not supported yet
  606. 255 ControlUtils.RdShwAndCntrlConst( ScreenFile, TmpFrame, '15' );
  607. ***** ^ not supported yet
  608. ***** ^ not supported yet
  609. ***** ^ not supported yet
  610. ***** ^ not supported yet
  611. ***** ^ not supported yet
  612. 256 (*"Record successfully added" message*)
  613. 257 END;
  614. 258 ELSE
  615. 259 ControlUtils.RdShwAndCntrlConst( ScreenFile, TmpFrame, '17' );
  616. ***** ^ not supported yet
  617. ***** ^ not supported yet
  618. ***** ^ not supported yet
  619. ***** ^ not supported yet
  620. ***** ^ not supported yet
  621. 260 END;
  622. 261 ELSIF ch = 'D' THEN
  623. 262 (*Delete*)
  624. 263 ControlUtils.ReadInput( EntryFrame, RecName, 'name');
  625. ***** ^ not supported yet
  626. ***** ^ not supported yet
  627. ***** ^ not supported yet
  628. ***** ^ not supported yet
  629. ***** ^ not supported yet
  630. 264 IF MsgBox2.MsgOkay( TmpFrame, VWindows.SE,
  631. ***** ^ not supported yet
  632. ***** ^ not supported yet
  633. ***** ^ not supported yet
  634. ***** ^ not supported yet
  635. ***** ^ not supported yet
  636. 265 "Preparing to delete record. Please confirm." ) THEN
  637. ***** ^ not supported yet
  638. 266 IF NdxFiles.DeleteRecord( NdxFile, RecName) THEN
  639. ***** ^ not supported yet
  640. ***** ^ not supported yet
  641. ***** ^ not supported yet
  642. ***** ^ not supported yet
  643. 267 ControlUtils.RdShwAndCntrlConst( ScreenFile, TmpFrame, '14' );
  644. ***** ^ not supported yet
  645. ***** ^ not supported yet
  646. ***** ^ not supported yet
  647. ***** ^ not supported yet
  648. ***** ^ not supported yet
  649. 268 (* successfully deleted *)
  650. 269 ELSE
  651. 270 ControlUtils.RdShwAndCntrlConst( ScreenFile, TmpFrame, '11' );
  652. ***** ^ not supported yet
  653. ***** ^ not supported yet
  654. ***** ^ not supported yet
  655. ***** ^ not supported yet
  656. ***** ^ not supported yet
  657. 271 (* cannot delete this record *)
  658. 272 END;
  659. 273 END;
  660. 274 ELSIF ch = 'P' THEN
  661. 275 (* Print *)
  662. 276 PrintMenu();
  663. ***** ^ not supported yet
  664. ***** ^ not supported yet
  665. 277 FramePainter.ShowDisplayFrame( EntryFrame, 0, 0, 0, 0 );
  666. ***** ^ not supported yet
  667. ***** ^ not supported yet
  668. ***** ^ not supported yet
  669. ***** ^ not supported yet
  670. 278 ELSIF ch = 'E' THEN
  671. 279 (*Edit.*)
  672. 280 ControlUtils.Control( EntryFrame );
  673. ***** ^ not supported yet
  674. ***** ^ not supported yet
  675. ***** ^ not supported yet
  676. 281 END;
  677. 282 UNTIL PosUtils.Equal(NextName, '2');
  678. ***** ^ not supported yet
  679. ***** ^ not supported yet
  680. ***** ^ not supported yet
  681. ***** ^ not supported yet
  682. 283 (*Frame 2 is the Main Menu *)
  683. 284 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  684. ***** ^ not supported yet
  685. ***** ^ not supported yet
  686. ***** ^ not supported yet
  687. 285 END DoOneRecord;
  688. ***** ^ not supported yet
  689. 286
  690. 287
  691. 288 PROCEDURE ShowAllRecords( TheList: GenLists.GenList );
  692. ***** ^ not supported yet
  693. 289 VAR
  694. 290 cnt, lngth, TypeCode: CARDINAL;
  695. 291 TmpName: NdxTypes.RecNameStr;
  696. ***** ^ not supported yet
  697. 292 TmpFrame: ScrnTypes.DisplayFrame;
  698. ***** ^ not supported yet
  699. 293 BEGIN
  700. 294 ScrnTypes.InitDisplayFrame( TmpFrame, VWindows.CurrentWindow );
  701. ***** ^ not supported yet
  702. ***** ^ not supported yet
  703. ***** ^ not supported yet
  704. ***** ^ not supported yet
  705. ***** ^ not supported yet
  706. 295 ScrnUtl2.ReadAndShow( ScreenFile, TmpFrame, '42' );
  707. ***** ^ not supported yet
  708. ***** ^ not supported yet
  709. ***** ^ not supported yet
  710. ***** ^ not supported yet
  711. ***** ^ not supported yet
  712. 296 (* changes the line at the bottom that explains the special keys *)
  713. 297 lngth := GenLists.ListLength( TheList );
  714. ***** ^ not supported yet
  715. ***** ^ not supported yet
  716. ***** ^ not supported yet
  717. 298 cnt := 1;
  718. 299 WHILE (cnt <= lngth) DO
  719. 300 GenLists.GetElmt( TheList, cnt, TmpName, TypeCode );
  720. ***** ^ not supported yet
  721. ***** ^ not supported yet
  722. ***** ^ not supported yet
  723. ***** ^ not supported yet
  724. ***** ^ not supported yet
  725. 301 DoOneRecord( TmpName );
  726. ***** ^ not supported yet
  727. ***** ^ not supported yet
  728. 302 INC(cnt);
  729. ***** ^ undeclared identifier
  730. ***** ^ not supported yet
  731. 303 END;
  732. 304 ScrnUtl2.ReadAndShow( ScreenFile, TmpFrame, '1' );
  733. ***** ^ not supported yet
  734. ***** ^ not supported yet
  735. ***** ^ not supported yet
  736. ***** ^ not supported yet
  737. ***** ^ not supported yet
  738. 305 (* resets the bottom line explaining the special keys *)
  739. 306 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  740. ***** ^ not supported yet
  741. ***** ^ not supported yet
  742. ***** ^ not supported yet
  743. 307 END ShowAllRecords;
  744. ***** ^ not supported yet
  745. 308
  746. 309
  747. 310 PROCEDURE ProcessRecord();
  748. 311 VAR
  749. 312 spot, dumc, LandingField, KeyHit: CARDINAL;
  750. 313 done: BOOLEAN;
  751. 314 NdxRec: NdxTypes.NdxElement;
  752. ***** ^ not supported yet
  753. 315 NextFrame: ScrnTypes.AFrameName;
  754. ***** ^ not supported yet
  755. 316 TmpFrame: ScrnTypes.DisplayFrame;
  756. ***** ^ not supported yet
  757. 317 BEGIN
  758. 318 ScrnTypes.InitDisplayFrame( TmpFrame, VWindows.CurrentWindow );
  759. ***** ^ not supported yet
  760. ***** ^ not supported yet
  761. ***** ^ not supported yet
  762. ***** ^ not supported yet
  763. ***** ^ not supported yet
  764. 319 RecName := '';
  765. ***** ^ not supported yet
  766. ***** ^ incompatible assignment
  767. 320 REPEAT
  768. 321 NextFrame := '4'; (*the record selection form*)
  769. ***** ^ not supported yet
  770. 322 DspFiles.ReadDisplayFrame( ScreenFile, TmpFrame, NextFrame );
  771. ***** ^ not supported yet
  772. ***** ^ not supported yet
  773. ***** ^ not supported yet
  774. ***** ^ not supported yet
  775. ***** ^ not supported yet
  776. 323 REPEAT
  777. 324 ControlUtils.ChangeField( TmpFrame, RecName, 'name', TRUE );
  778. ***** ^ not supported yet
  779. ***** ^ not supported yet
  780. ***** ^ not supported yet
  781. ***** ^ not supported yet
  782. ***** ^ not supported yet
  783. ***** ^ not supported yet
  784. 325 FramePainter.ShowDisplayFrame( TmpFrame, 0, 0, 0, 0 );
  785. ***** ^ not supported yet
  786. ***** ^ not supported yet
  787. ***** ^ not supported yet
  788. ***** ^ not supported yet
  789. 326 LandingField := 0;
  790. 327 InputManager.ControlFrame( TmpFrame,
  791. ***** ^ not supported yet
  792. ***** ^ not supported yet
  793. ***** ^ not supported yet
  794. 328 LandingField, '', FALSE, NextFrame );
  795. ***** ^ not supported yet
  796. 329 IF NOT PosUtils.Equal( NextFrame, TmpFrame^.normlnext ) THEN
  797. ***** ^ not supported yet
  798. ***** ^ not supported yet
  799. ***** ^ not supported yet
  800. ***** ^ not supported yet
  801. ***** ^ not supported yet
  802. 330 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  803. ***** ^ not supported yet
  804. ***** ^ not supported yet
  805. ***** ^ not supported yet
  806. 331 RETURN;
  807. 332 END;
  808. 333 ControlUtils.ReadInput( TmpFrame, RecName, 'name');
  809. ***** ^ not supported yet
  810. ***** ^ not supported yet
  811. ***** ^ not supported yet
  812. ***** ^ not supported yet
  813. ***** ^ not supported yet
  814. 334 done := NdxFiles.RecordExists( NdxFile, RecName);
  815. ***** ^ not supported yet
  816. ***** ^ not supported yet
  817. ***** ^ not supported yet
  818. ***** ^ not supported yet
  819. 335 IF NOT done THEN
  820. 336 done := MsgBox2.MsgOkay( TmpFrame, VWindows.SE,
  821. ***** ^ not supported yet
  822. ***** ^ not supported yet
  823. ***** ^ not supported yet
  824. ***** ^ not supported yet
  825. ***** ^ not supported yet
  826. 337 "Record not found. Preparing to create it. Please confirm." );
  827. ***** ^ not supported yet
  828. 338 END;
  829. 339 IF NOT done THEN
  830. 340 IF MsgBox2.MsgOkay( TmpFrame, VWindows.SE,
  831. ***** ^ not supported yet
  832. ***** ^ not supported yet
  833. ***** ^ not supported yet
  834. ***** ^ not supported yet
  835. ***** ^ not supported yet
  836. 341 "Search for a name in which this pattern appears?" ) THEN
  837. ***** ^ not supported yet
  838. 342 StrEdit.CrunchBlanks( RecName );
  839. ***** ^ not supported yet
  840. ***** ^ not supported yet
  841. ***** ^ not supported yet
  842. 343 spot := GenLists.ScanList( RecName, NdxFile^.Ndx,
  843. ***** ^ not supported yet
  844. ***** ^ not supported yet
  845. ***** ^ not supported yet
  846. ***** ^ not supported yet
  847. ***** ^ not supported yet
  848. 344 1, 65535, dumc );
  849. ***** ^ not supported yet
  850. 345 IF spot > 0 THEN
  851. 346 GenLists.GetElmt( NdxFile^.Ndx, spot, NdxRec, dumc );
  852. ***** ^ not supported yet
  853. ***** ^ not supported yet
  854. ***** ^ not supported yet
  855. ***** ^ not supported yet
  856. ***** ^ not supported yet
  857. ***** ^ not supported yet
  858. 347 M2Strings.Assign( NdxRec.RecName, RecName );
  859. ***** ^ not supported yet
  860. ***** ^ not supported yet
  861. ***** ^ not supported yet
  862. ***** ^ not supported yet
  863. ***** ^ not supported yet
  864. 348 ELSE
  865. 349 RecName := '';
  866. ***** ^ not supported yet
  867. ***** ^ incompatible assignment
  868. 350 END;
  869. 351 END;
  870. 352 END;
  871. 353 UNTIL done;
  872. 354 DoOneRecord( RecName );
  873. ***** ^ not supported yet
  874. ***** ^ not supported yet
  875. 355 UNTIL NOT PosUtils.Equal( NextFrame, '4' );
  876. ***** ^ not supported yet
  877. ***** ^ not supported yet
  878. ***** ^ not supported yet
  879. ***** ^ not supported yet
  880. 356 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  881. ***** ^ not supported yet
  882. ***** ^ not supported yet
  883. ***** ^ not supported yet
  884. 357 END ProcessRecord;
  885. ***** ^ not supported yet
  886. 358
  887. 359
  888. 360 PROCEDURE StoreList( TheList: GenLists.GenList );
  889. ***** ^ not supported yet
  890. 361 VAR
  891. 362 ListName: ARRAY [0..79] OF CHAR;
  892. ***** ^ not supported yet
  893. ***** ^ not supported yet
  894. 363 TmpList: GenLists.GenList;
  895. ***** ^ not supported yet
  896. 364 NextFrame: ScrnTypes.AFrameName;
  897. ***** ^ not supported yet
  898. 365 TmpFrame: ScrnTypes.DisplayFrame;
  899. ***** ^ not supported yet
  900. 366 BEGIN
  901. 367 ScrnTypes.InitDisplayFrame( TmpFrame, VWindows.CurrentWindow );
  902. ***** ^ not supported yet
  903. ***** ^ not supported yet
  904. ***** ^ not supported yet
  905. ***** ^ not supported yet
  906. ***** ^ not supported yet
  907. 368 NextFrame := '20';
  908. ***** ^ not supported yet
  909. ***** ^ not supported yet
  910. 369 (*List Storage Form*)
  911. 370 DspFiles.ReadDisplayFrame( ScreenFile, TmpFrame,
  912. ***** ^ not supported yet
  913. ***** ^ not supported yet
  914. ***** ^ not supported yet
  915. ***** ^ not supported yet
  916. 371 NextFrame );
  917. ***** ^ not supported yet
  918. 372 IF NOT (0 # ScrnUtl1.FieldNum( TmpFrame, 'list' )) THEN
  919. ***** ^ not supported yet
  920. ***** ^ not supported yet
  921. ***** ^ not supported yet
  922. ***** ^ not supported yet
  923. 373 (*Find the editor field.*)
  924. 374 HALT();
  925. ***** ^ undeclared identifier
  926. ***** ^ not supported yet
  927. 375 END;
  928. 376 IF NOT ScrnUtl1.ListToEdField( TheList, TmpFrame,
  929. ***** ^ not supported yet
  930. ***** ^ not supported yet
  931. ***** ^ not supported yet
  932. ***** ^ not supported yet
  933. 377 TmpFrame^.CurrentField ) THEN
  934. ***** ^ not supported yet
  935. ***** ^ not supported yet
  936. 378 (*Put the list created in BuildList into the editor
  937. 379 field.*)
  938. 380 HALT();
  939. ***** ^ undeclared identifier
  940. ***** ^ not supported yet
  941. 381 END;
  942. 382 StrConv.CardinalToStr( GenLists.ListLength( TheList), 0, ListName);
  943. ***** ^ not supported yet
  944. ***** ^ not supported yet
  945. ***** ^ not supported yet
  946. ***** ^ not supported yet
  947. ***** ^ not supported yet
  948. ***** ^ not supported yet
  949. 383 StrEdit.Append( ListName, '.');
  950. ***** ^ not supported yet
  951. ***** ^ not supported yet
  952. ***** ^ not supported yet
  953. ***** ^ not supported yet
  954. 384 ControlUtils.ChangeField( TmpFrame, ListName, 'size', FALSE);
  955. ***** ^ not supported yet
  956. ***** ^ not supported yet
  957. ***** ^ not supported yet
  958. ***** ^ not supported yet
  959. ***** ^ not supported yet
  960. ***** ^ not supported yet
  961. 385 FramePainter.ShowDisplayFrame( TmpFrame, 0, 0, 0, 0 );
  962. ***** ^ not supported yet
  963. ***** ^ not supported yet
  964. ***** ^ not supported yet
  965. ***** ^ not supported yet
  966. 386 REPEAT
  967. 387 InputManager.ControlFrame( TmpFrame, 0, '', FALSE, NextFrame );
  968. ***** ^ not supported yet
  969. ***** ^ not supported yet
  970. ***** ^ not supported yet
  971. ***** ^ not supported yet
  972. 388 IF PosUtils.Equal( NextFrame, '999' ) THEN
  973. ***** ^ not supported yet
  974. ***** ^ not supported yet
  975. ***** ^ not supported yet
  976. ***** ^ not supported yet
  977. 389 (*They want to store the list.*)
  978. 390 ControlUtils.ReadInput( TmpFrame, ListName, 'name' );
  979. ***** ^ not supported yet
  980. ***** ^ not supported yet
  981. ***** ^ not supported yet
  982. ***** ^ not supported yet
  983. ***** ^ not supported yet
  984. 391 (*Get the name they've chosen for the list out of
  985. 392 the 'name' field.*)
  986. 393 GenLists.CopyList( TheList, TmpList );
  987. ***** ^ not supported yet
  988. ***** ^ not supported yet
  989. ***** ^ not supported yet
  990. ***** ^ not supported yet
  991. 394 IF NOT BuildLst.StoreRecNameList( NdxFile, ListName, TmpList ) THEN
  992. ***** ^ not supported yet
  993. ***** ^ not supported yet
  994. ***** ^ not supported yet
  995. ***** ^ not supported yet
  996. ***** ^ not supported yet
  997. 395 HALT();
  998. ***** ^ undeclared identifier
  999. ***** ^ not supported yet
  1000. 396 END;
  1001. 397 ScrnUtl2.ShowMessage( ScreenFile, '27' );
  1002. ***** ^ not supported yet
  1003. ***** ^ not supported yet
  1004. ***** ^ not supported yet
  1005. ***** ^ not supported yet
  1006. 398 (*Says store successful; waits for any key.*)
  1007. 399 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  1008. ***** ^ not supported yet
  1009. ***** ^ not supported yet
  1010. ***** ^ not supported yet
  1011. 400 RETURN;
  1012. 401 END;
  1013. 402 UNTIL PosUtils.Equal( NextFrame, '21' );
  1014. ***** ^ not supported yet
  1015. ***** ^ not supported yet
  1016. ***** ^ not supported yet
  1017. ***** ^ not supported yet
  1018. 403 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  1019. ***** ^ not supported yet
  1020. ***** ^ not supported yet
  1021. ***** ^ not supported yet
  1022. 404 END StoreList;
  1023. ***** ^ not supported yet
  1024. 405
  1025. 406
  1026. 407 PROCEDURE SearchFile();
  1027. 408 VAR
  1028. 409 ListMade: GenLists.GenList;
  1029. ***** ^ not supported yet
  1030. 410 ErrorField: CARDINAL;
  1031. 411 message, LimitingList: ARRAY [0..79] OF CHAR;
  1032. ***** ^ not supported yet
  1033. ***** ^ not supported yet
  1034. 412 dumbool: BOOLEAN;
  1035. 413 NextFrame: ScrnTypes.AFrameName;
  1036. ***** ^ not supported yet
  1037. 414 MsgFrame, TmpFrame: ScrnTypes.DisplayFrame;
  1038. ***** ^ not supported yet
  1039. 415
  1040. 416 BEGIN (*SearchFile*)
  1041. 417 ScrnTypes.InitDisplayFrame( TmpFrame, VWindows.CurrentWindow );
  1042. ***** ^ not supported yet
  1043. ***** ^ not supported yet
  1044. ***** ^ not supported yet
  1045. ***** ^ not supported yet
  1046. ***** ^ not supported yet
  1047. 418 LOOP
  1048. 419 StrEdit.AssignStr( '', message );
  1049. ***** ^ not supported yet
  1050. ***** ^ not supported yet
  1051. ***** ^ not supported yet
  1052. 420 ErrorField := 0;
  1053. 421 NextFrame := '21'; (*The List Building form*)
  1054. ***** ^ not supported yet
  1055. ***** ^ not supported yet
  1056. 422 ScrnUtl2.ReadAndShow( ScreenFile, TmpFrame, NextFrame );
  1057. ***** ^ not supported yet
  1058. ***** ^ not supported yet
  1059. ***** ^ not supported yet
  1060. ***** ^ not supported yet
  1061. ***** ^ not supported yet
  1062. 423 REPEAT
  1063. 424 InputManager.ControlFrame( TmpFrame, ErrorField,
  1064. ***** ^ not supported yet
  1065. ***** ^ not supported yet
  1066. ***** ^ not supported yet
  1067. 425 message, FALSE, NextFrame );
  1068. ***** ^ not supported yet
  1069. ***** ^ not supported yet
  1070. 426 ErrorField := 0;
  1071. 427 (*Reset ErrorField and message so they'll signal an
  1072. 428 error on the next loop only if there's really been
  1073. 429 an error.*)
  1074. 430 StrEdit.AssignStr( '', message );
  1075. ***** ^ not supported yet
  1076. ***** ^ not supported yet
  1077. ***** ^ not supported yet
  1078. 431 IF NOT PosUtils.Equal( NextFrame, TmpFrame^.normlnext ) THEN
  1079. ***** ^ not supported yet
  1080. ***** ^ not supported yet
  1081. ***** ^ not supported yet
  1082. ***** ^ not supported yet
  1083. ***** ^ not supported yet
  1084. 432 (*exit if they press the backup or program-exit
  1085. 433 keys.*)
  1086. 434 EXIT;
  1087. 435 END;
  1088. 436 IF NOT ScrnUtl1.FieldIsBlank( TmpFrame,
  1089. ***** ^ not supported yet
  1090. ***** ^ not supported yet
  1091. ***** ^ not supported yet
  1092. 437 'listname', ErrorField) THEN
  1093. ***** ^ not supported yet
  1094. ***** ^ not supported yet
  1095. 438 ControlUtils.ReadInput( TmpFrame, LimitingList, 'listname' );
  1096. ***** ^ not supported yet
  1097. ***** ^ not supported yet
  1098. ***** ^ not supported yet
  1099. ***** ^ not supported yet
  1100. ***** ^ not supported yet
  1101. 439 (*Get the name of the list they've chosen to use
  1102. 440 out of the 'name' field.*)
  1103. 441 ELSE
  1104. 442 StrEdit.AssignStr( '', LimitingList );
  1105. ***** ^ not supported yet
  1106. ***** ^ not supported yet
  1107. ***** ^ not supported yet
  1108. 443 END;
  1109. 444 ScrnTypes.InitDisplayFrame( MsgFrame, VWindows.CurrentWindow );
  1110. ***** ^ not supported yet
  1111. ***** ^ not supported yet
  1112. ***** ^ not supported yet
  1113. ***** ^ not supported yet
  1114. ***** ^ not supported yet
  1115. 445 ScrnUtl2.ReadAndShow( ScreenFile, MsgFrame, '43' );
  1116. ***** ^ not supported yet
  1117. ***** ^ not supported yet
  1118. ***** ^ not supported yet
  1119. ***** ^ not supported yet
  1120. ***** ^ not supported yet
  1121. 446 (*a screen that says list is being created *)
  1122. 447 BuildLst.BuildList( NdxFile, TmpFrame, 1, 13, LimitingList,
  1123. ***** ^ not supported yet
  1124. ***** ^ not supported yet
  1125. ***** ^ not supported yet
  1126. ***** ^ not supported yet
  1127. ***** ^ not supported yet
  1128. 448 ErrorField, ListMade );
  1129. ***** ^ not supported yet
  1130. 449 FrameManager.EraseFrame( MsgFrame );
  1131. ***** ^ not supported yet
  1132. ***** ^ not supported yet
  1133. ***** ^ not supported yet
  1134. 450 ScrnUtl2.CloseDisplayFrame( MsgFrame );
  1135. ***** ^ not supported yet
  1136. ***** ^ not supported yet
  1137. ***** ^ not supported yet
  1138. 451 IF ErrorField = 0 THEN
  1139. 452 BuildLst.DeleteListRec( ListMade);
  1140. ***** ^ not supported yet
  1141. ***** ^ not supported yet
  1142. ***** ^ not supported yet
  1143. 453 StoreList( ListMade );
  1144. ***** ^ not supported yet
  1145. ***** ^ not supported yet
  1146. 454 EXIT;
  1147. 455 ELSE
  1148. 456 StrEdit.AssignStr( "Something's wrong with this field.",
  1149. ***** ^ not supported yet
  1150. ***** ^ not supported yet
  1151. ***** ^ not supported yet
  1152. 457 message );
  1153. ***** ^ not supported yet
  1154. 458 END;
  1155. 459 UNTIL ErrorField = 0;
  1156. 460 END;
  1157. 461 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  1158. ***** ^ not supported yet
  1159. ***** ^ not supported yet
  1160. ***** ^ not supported yet
  1161. 462 END SearchFile;
  1162. ***** ^ not supported yet
  1163. 463
  1164. 464
  1165. 465 PROCEDURE ManageLists();
  1166. 466 VAR
  1167. 467 TmpList: GenLists.GenList;
  1168. ***** ^ not supported yet
  1169. 468 LastListName : ARRAY [0..79] OF CHAR;
  1170. ***** ^ not supported yet
  1171. ***** ^ not supported yet
  1172. 469 NextFrame: ScrnTypes.AFrameName;
  1173. ***** ^ not supported yet
  1174. 470 TmpFrame: ScrnTypes.DisplayFrame;
  1175. ***** ^ not supported yet
  1176. 471 BEGIN
  1177. 472 ScrnTypes.InitDisplayFrame( TmpFrame, VWindows.CurrentWindow );
  1178. ***** ^ not supported yet
  1179. ***** ^ not supported yet
  1180. ***** ^ not supported yet
  1181. ***** ^ not supported yet
  1182. ***** ^ not supported yet
  1183. 473 LastListName[0] := 0C;
  1184. ***** ^ not supported yet
  1185. ***** ^ not supported yet
  1186. 474 LOOP
  1187. 475 NextFrame := '29'; (*The main list management menu.*)
  1188. ***** ^ not supported yet
  1189. ***** ^ not supported yet
  1190. 476 ControlUtils.ReadShowAndCntrl( ScreenFile, TmpFrame, NextFrame );
  1191. ***** ^ not supported yet
  1192. ***** ^ not supported yet
  1193. ***** ^ not supported yet
  1194. ***** ^ not supported yet
  1195. ***** ^ not supported yet
  1196. 477 IF PosUtils.Equal( NextFrame, TmpFrame^.parent ) THEN
  1197. ***** ^ not supported yet
  1198. ***** ^ not supported yet
  1199. ***** ^ not supported yet
  1200. ***** ^ not supported yet
  1201. ***** ^ not supported yet
  1202. 478 EXIT;
  1203. 479 END;
  1204. 480 CASE ScrnUtl1.SelectedChar(TmpFrame) OF
  1205. ***** ^ not supported yet
  1206. ***** ^ not supported yet
  1207. ***** ^ not supported yet
  1208. 481 'M': (*Make a new list.*)
  1209. 482 SearchFile();
  1210. ***** ^ not supported yet
  1211. ***** ^ not supported yet
  1212. 483 | 'D': (*Delete a list.*)
  1213. 484 IF ControlUtils.GetStrResponse( ScreenFile,
  1214. ***** ^ not supported yet
  1215. ***** ^ not supported yet
  1216. ***** ^ not supported yet
  1217. 485 '30', LastListName, LastListName ) THEN
  1218. ***** ^ not supported yet
  1219. ***** ^ not supported yet
  1220. ***** ^ not supported yet
  1221. 486 (* if they didn't try to back up or exit *)
  1222. 487 IF BuildLst.DelRecNameList( NdxFile,
  1223. ***** ^ not supported yet
  1224. ***** ^ not supported yet
  1225. ***** ^ not supported yet
  1226. 488 LastListName ) THEN
  1227. ***** ^ not supported yet
  1228. 489 ScrnUtl2.ShowMessage( ScreenFile, '34' );
  1229. ***** ^ not supported yet
  1230. ***** ^ not supported yet
  1231. ***** ^ not supported yet
  1232. ***** ^ not supported yet
  1233. 490 (*Says the list was successfully deleted.*)
  1234. 491 ELSE
  1235. 492 ScrnUtl2.ShowMessage( ScreenFile, '35' );
  1236. ***** ^ not supported yet
  1237. ***** ^ not supported yet
  1238. ***** ^ not supported yet
  1239. ***** ^ not supported yet
  1240. 493 (*Says no such list stored; waits for any key.*)
  1241. 494 END;
  1242. 495 END;
  1243. 496 | 'S': (*Show lists.*)
  1244. 497 IF BuildLst.GetListNames( NdxFile, TmpList ) AND
  1245. ***** ^ not supported yet
  1246. ***** ^ not supported yet
  1247. ***** ^ not supported yet
  1248. ***** ^ not supported yet
  1249. 498 (GenLists.ListLength( TmpList) # 0) THEN
  1250. ***** ^ not supported yet
  1251. ***** ^ not supported yet
  1252. ***** ^ not supported yet
  1253. 499 IF NOT ControlUtils.ListBox( ScreenFile, '31',
  1254. ***** ^ not supported yet
  1255. ***** ^ not supported yet
  1256. ***** ^ not supported yet
  1257. ***** ^ not supported yet
  1258. 500 TmpList, LastListName, NextFrame ) THEN
  1259. ***** ^ not supported yet
  1260. ***** ^ not supported yet
  1261. ***** ^ not supported yet
  1262. 501 (* We don't care if they press Esc here. *)
  1263. 502 END;
  1264. 503 ELSE
  1265. 504 ScrnUtl2.ShowMessage( ScreenFile, '35' );
  1266. ***** ^ not supported yet
  1267. ***** ^ not supported yet
  1268. ***** ^ not supported yet
  1269. ***** ^ not supported yet
  1270. 505 (*Says no such list stored and waits for a key.*)
  1271. 506 END;
  1272. 507 | 'E': (*Edit a list.*)
  1273. 508 IF ControlUtils.GetStrResponse( ScreenFile,
  1274. ***** ^ not supported yet
  1275. ***** ^ not supported yet
  1276. ***** ^ not supported yet
  1277. 509 '32', LastListName, LastListName ) THEN
  1278. ***** ^ not supported yet
  1279. ***** ^ not supported yet
  1280. ***** ^ not supported yet
  1281. 510 (* if they didn't try to back up or exit *)
  1282. 511 IF BuildLst.GetRecNameList( NdxFile,
  1283. ***** ^ not supported yet
  1284. ***** ^ not supported yet
  1285. ***** ^ not supported yet
  1286. 512 LastListName, TmpList ) THEN
  1287. ***** ^ not supported yet
  1288. ***** ^ not supported yet
  1289. 513 StoreList( TmpList );
  1290. ***** ^ not supported yet
  1291. ***** ^ not supported yet
  1292. 514 ELSE
  1293. 515 ScrnUtl2.ShowMessage( ScreenFile, '35' );
  1294. ***** ^ not supported yet
  1295. ***** ^ not supported yet
  1296. ***** ^ not supported yet
  1297. ***** ^ not supported yet
  1298. 516 (*Says no such list stored; waits for any key.*)
  1299. 517 END;
  1300. 518 END;
  1301. 519 | 'A': (*Examine list of All records.*)
  1302. 520 NdxUtils.GetRecNames( NdxFile, TmpList );
  1303. ***** ^ not supported yet
  1304. ***** ^ not supported yet
  1305. ***** ^ not supported yet
  1306. ***** ^ not supported yet
  1307. 521 StoreList( TmpList );
  1308. ***** ^ not supported yet
  1309. ***** ^ not supported yet
  1310. 522 | 'R': (*Retrieve listed records.*)
  1311. 523 IF ControlUtils.GetStrResponse( ScreenFile,
  1312. ***** ^ not supported yet
  1313. ***** ^ not supported yet
  1314. ***** ^ not supported yet
  1315. 524 '33', LastListName, LastListName ) THEN
  1316. ***** ^ not supported yet
  1317. ***** ^ not supported yet
  1318. ***** ^ not supported yet
  1319. 525 (* if they didn't try to back up or exit *)
  1320. 526 IF BuildLst.GetRecNameList( NdxFile,
  1321. ***** ^ not supported yet
  1322. ***** ^ not supported yet
  1323. ***** ^ not supported yet
  1324. 527 LastListName, TmpList ) THEN
  1325. ***** ^ not supported yet
  1326. ***** ^ not supported yet
  1327. 528 ShowAllRecords( TmpList );
  1328. ***** ^ not supported yet
  1329. ***** ^ not supported yet
  1330. 529 NextFrame := '29'; (* The main list management menu. *)
  1331. ***** ^ not supported yet
  1332. ***** ^ not supported yet
  1333. 530 ELSE
  1334. 531 ScrnUtl2.ShowMessage( ScreenFile, '35' );
  1335. ***** ^ not supported yet
  1336. ***** ^ not supported yet
  1337. ***** ^ not supported yet
  1338. ***** ^ not supported yet
  1339. 532 (*Says no such list stored; waits for any key.*)
  1340. 533 END;
  1341. 534 END;
  1342. 535 ELSE
  1343. 536 END;
  1344. 537 END;
  1345. 538 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  1346. ***** ^ not supported yet
  1347. ***** ^ not supported yet
  1348. ***** ^ not supported yet
  1349. 539 END ManageLists;
  1350. ***** ^ not supported yet
  1351. 540
  1352. 541
  1353. 542
  1354. 543 PROCEDURE ErrorOpeningFile( ErrMsg: CARDINAL;
  1355. 544 ErrText, fname: ARRAY OF CHAR );
  1356. ***** ^ not supported yet
  1357. 545 VAR
  1358. 546 TmpStr1: ARRAY [0..149] OF CHAR;
  1359. ***** ^ not supported yet
  1360. ***** ^ not supported yet
  1361. 547 TmpStr2: ARRAY [0..59] OF CHAR;
  1362. ***** ^ not supported yet
  1363. ***** ^ not supported yet
  1364. 548 KeyHit: CARDINAL;
  1365. 549 BEGIN
  1366. 550 StrEdit.AssignStr( "Error in opening '", TmpStr1 );
  1367. ***** ^ not supported yet
  1368. ***** ^ not supported yet
  1369. ***** ^ not supported yet
  1370. ***** ^ not supported yet
  1371. 551 StrEdit.Append( TmpStr1, fname );
  1372. ***** ^ not supported yet
  1373. ***** ^ not supported yet
  1374. ***** ^ not supported yet
  1375. ***** ^ not supported yet
  1376. 552 StrEdit.Append( TmpStr1, "': " );
  1377. ***** ^ not supported yet
  1378. ***** ^ not supported yet
  1379. ***** ^ not supported yet
  1380. ***** ^ not supported yet
  1381. 553 IF ErrMsg # StringIO.MissingMessage THEN
  1382. ***** ^ not supported yet
  1383. ***** ^ not supported yet
  1384. 554 ErrStrgs.NumToStr( ErrMsg, TmpStr2 );
  1385. ***** ^ not supported yet
  1386. ***** ^ not supported yet
  1387. ***** ^ not supported yet
  1388. 555 StrEdit.Append( TmpStr1, TmpStr2 );
  1389. ***** ^ not supported yet
  1390. ***** ^ not supported yet
  1391. ***** ^ not supported yet
  1392. ***** ^ not supported yet
  1393. 556 ELSE
  1394. 557 StrEdit.Append( TmpStr1, ErrText);
  1395. ***** ^ not supported yet
  1396. ***** ^ not supported yet
  1397. ***** ^ not supported yet
  1398. ***** ^ not supported yet
  1399. 558 END;
  1400. 559 StrEdit.Append( TmpStr1, " Press any key." );
  1401. ***** ^ not supported yet
  1402. ***** ^ not supported yet
  1403. ***** ^ not supported yet
  1404. ***** ^ not supported yet
  1405. 560 WindowPrims.MsgBox( VWindows.SE, TmpStr1, KbdInput.AnyKeyNum, KeyHit );
  1406. ***** ^ not supported yet
  1407. ***** ^ not supported yet
  1408. ***** ^ not supported yet
  1409. ***** ^ not supported yet
  1410. ***** ^ not supported yet
  1411. ***** ^ not supported yet
  1412. ***** ^ not supported yet
  1413. ***** ^ not supported yet
  1414. 561 END ErrorOpeningFile;
  1415. ***** ^ not supported yet
  1416. 562
  1417. 563
  1418. 564 PROCEDURE NotPmiFile( fname: ARRAY OF CHAR): BOOLEAN;
  1419. ***** ^ not supported yet
  1420. 565 BEGIN
  1421. 566 RETURN NOT PosUtils.Present( 'pmidbms', fname);
  1422. ***** ^ not supported yet
  1423. ***** ^ not supported yet
  1424. ***** ^ not supported yet
  1425. ***** ^ not supported yet
  1426. 567 END NotPmiFile;
  1427. ***** ^ not supported yet
  1428. 568
  1429. 569
  1430. 570 PROCEDURE ExportRecords( NdxFile: NdxTypes.NdxFileType; VAR NextFrame:
  1431. ***** ^ not supported yet
  1432. 571 ScrnTypes.AFrameName; ScreenFile: ScrnTypes.DisplayFile);
  1433. ***** ^ not supported yet
  1434. ***** ^ not supported yet
  1435. 572
  1436. 573 VAR
  1437. 574 TmpFrame: ScrnTypes.DisplayFrame;
  1438. ***** ^ not supported yet
  1439. 575
  1440. 576
  1441. 577 PROCEDURE ExportToNdxFile( NdxF1: NdxTypes.NdxFileType; RecNameList,
  1442. ***** ^ not supported yet
  1443. 578 MatchingFields: GenLists.GenList; NdxF2: NdxTypes.NdxFileType );
  1444. ***** ^ not supported yet
  1445. ***** ^ not supported yet
  1446. 579
  1447. 580 VAR
  1448. 581 SearchingAll: BOOLEAN;
  1449. 582 TypeCode, lngth1, cnt: CARDINAL;
  1450. 583 TmpStr: NdxTypes.RecNameStr;
  1451. ***** ^ not supported yet
  1452. 584 TmpNdxRec: NdxTypes.NdxElement;
  1453. ***** ^ not supported yet
  1454. 585
  1455. 586 BEGIN (* ExportToNdxFile *)
  1456. 587 lngth1 := GenLists.ListLength( RecNameList );
  1457. ***** ^ not supported yet
  1458. ***** ^ not supported yet
  1459. ***** ^ not supported yet
  1460. 588 IF lngth1 = 0 THEN
  1461. 589 SearchingAll := TRUE;
  1462. 590 lngth1 := GenLists.ListLength( NdxF1^.Ndx );
  1463. ***** ^ not supported yet
  1464. ***** ^ not supported yet
  1465. ***** ^ not supported yet
  1466. ***** ^ not supported yet
  1467. 591 ELSE
  1468. 592 SearchingAll := FALSE;
  1469. 593 END;
  1470. 594 ScrnUtl2.ReadAndShow( ScreenFile, TmpFrame, '38' );
  1471. ***** ^ not supported yet
  1472. ***** ^ not supported yet
  1473. ***** ^ not supported yet
  1474. ***** ^ not supported yet
  1475. ***** ^ not supported yet
  1476. 595 FOR cnt := 1 TO lngth1 DO
  1477. 596 IF SearchingAll THEN
  1478. 597 GenLists.GetElmt( NdxF1^.Ndx, cnt, TmpNdxRec, TypeCode );
  1479. ***** ^ not supported yet
  1480. ***** ^ not supported yet
  1481. ***** ^ not supported yet
  1482. ***** ^ not supported yet
  1483. ***** ^ not supported yet
  1484. ***** ^ not supported yet
  1485. 598 StrEdit.AssignStr( TmpNdxRec.RecName, TmpStr );
  1486. ***** ^ not supported yet
  1487. ***** ^ not supported yet
  1488. ***** ^ not supported yet
  1489. ***** ^ not supported yet
  1490. ***** ^ not supported yet
  1491. 599 ELSE
  1492. 600 GenLists.GetElmt( RecNameList, cnt, TmpStr, TypeCode );
  1493. ***** ^ not supported yet
  1494. ***** ^ not supported yet
  1495. ***** ^ not supported yet
  1496. ***** ^ not supported yet
  1497. ***** ^ not supported yet
  1498. 601 (*Put the cnt'th record name in TmpStr.*)
  1499. 602 END;
  1500. 603 IF (M2Strings.Length( TmpStr ) > 0) AND
  1501. ***** ^ not supported yet
  1502. ***** ^ not supported yet
  1503. ***** ^ not supported yet
  1504. 604 (0 # M2Strings.CompareStr( TmpStr, BuildLst.ListStorageRec)) THEN
  1505. ***** ^ not supported yet
  1506. ***** ^ not supported yet
  1507. ***** ^ not supported yet
  1508. ***** ^ not supported yet
  1509. ***** ^ not supported yet
  1510. 605 (* don't export the special record of list names *)
  1511. 606 NdxUtils.CopyMatchingFields( NdxF1, NdxF2, TmpStr, MatchingFields );
  1512. ***** ^ not supported yet
  1513. ***** ^ not supported yet
  1514. ***** ^ not supported yet
  1515. ***** ^ not supported yet
  1516. ***** ^ not supported yet
  1517. ***** ^ not supported yet
  1518. 607 END;
  1519. 608 END;
  1520. 609 END ExportToNdxFile;
  1521. ***** ^ not supported yet
  1522. 610
  1523. 611 CONST
  1524. 612 FillThisField =
  1525. 613 'Your selection requires completion of this field. Press any key.';
  1526. ***** ^ not supported yet
  1527. 614 VAR
  1528. 615 fname, ListName, TmpStr1, TmpStr2, message: ARRAY [0..79]
  1529. ***** ^ not supported yet
  1530. 616 OF CHAR;
  1531. ***** ^ not supported yet
  1532. 617 MatchingFieldList, RecNameList: GenLists.GenList;
  1533. ***** ^ not supported yet
  1534. 618 DestNdxFile: NdxTypes.NdxFileType;
  1535. ***** ^ not supported yet
  1536. 619 done: BOOLEAN;
  1537. 620 SavedMessage: CARDINAL;
  1538. 621 TmpFieldRec: ScrnTypes.InputFieldRecord;
  1539. ***** ^ not supported yet
  1540. 622 ErrField, ExpFile, KeyHit: CARDINAL;
  1541. 623
  1542. 624 PROCEDURE AllFieldsCorrect( TheFrame: ScrnTypes.DisplayFrame;
  1543. ***** ^ not supported yet
  1544. 625 ReqFieldName: ARRAY OF CHAR; VAR BadFieldNum: CARDINAL;
  1545. ***** ^ not supported yet
  1546. 626 VAR message, DestFileName: ARRAY OF CHAR; ListFieldName:
  1547. ***** ^ not supported yet
  1548. 627 ARRAY OF CHAR; VAR RecNameList: GenLists.GenList ): BOOLEAN;
  1549. ***** ^ not supported yet
  1550. ***** ^ not supported yet
  1551. 628 VAR
  1552. 629 ListName: ARRAY [0..79] OF CHAR;
  1553. ***** ^ not supported yet
  1554. ***** ^ not supported yet
  1555. 630 dumbool : BOOLEAN;
  1556. 631 BEGIN
  1557. 632 IF ScrnUtl1.FieldIsBlank( TheFrame, ReqFieldName, BadFieldNum ) THEN
  1558. ***** ^ not supported yet
  1559. ***** ^ not supported yet
  1560. ***** ^ not supported yet
  1561. ***** ^ not supported yet
  1562. ***** ^ not supported yet
  1563. 633 StrEdit.AssignStr( FillThisField, message );
  1564. ***** ^ not supported yet
  1565. ***** ^ not supported yet
  1566. ***** ^ not supported yet
  1567. ***** ^ not supported yet
  1568. 634 done := FALSE;
  1569. 635 ELSE
  1570. 636 ControlUtils.ReadInput( TheFrame, DestFileName, ReqFieldName );
  1571. ***** ^ not supported yet
  1572. ***** ^ not supported yet
  1573. ***** ^ not supported yet
  1574. ***** ^ not supported yet
  1575. ***** ^ not supported yet
  1576. 637 StrEdit.DeleteChar( ' ', DestFileName );
  1577. ***** ^ not supported yet
  1578. ***** ^ not supported yet
  1579. ***** ^ not supported yet
  1580. 638 IF ScrnUtl1.FieldIsBlank( TheFrame, ListFieldName, BadFieldNum ) THEN
  1581. ***** ^ not supported yet
  1582. ***** ^ not supported yet
  1583. ***** ^ not supported yet
  1584. ***** ^ not supported yet
  1585. ***** ^ not supported yet
  1586. 639 StrEdit.AssignStr( FillThisField, message );
  1587. ***** ^ not supported yet
  1588. ***** ^ not supported yet
  1589. ***** ^ not supported yet
  1590. ***** ^ not supported yet
  1591. 640 GenLists.NewList( RecNameList );
  1592. ***** ^ not supported yet
  1593. ***** ^ not supported yet
  1594. ***** ^ not supported yet
  1595. 641 BadFieldNum := 0;
  1596. 642 done := TRUE;
  1597. 643 ELSE
  1598. 644 ControlUtils.ReadInput( TheFrame, ListName, ListFieldName);
  1599. ***** ^ not supported yet
  1600. ***** ^ not supported yet
  1601. ***** ^ not supported yet
  1602. ***** ^ not supported yet
  1603. ***** ^ not supported yet
  1604. 645 IF NOT BuildLst.GetRecNameList( NdxFile, ListName,
  1605. ***** ^ not supported yet
  1606. ***** ^ not supported yet
  1607. ***** ^ not supported yet
  1608. ***** ^ not supported yet
  1609. 646 RecNameList ) THEN
  1610. ***** ^ not supported yet
  1611. 647 done := FALSE;
  1612. 648 StrEdit.AssignStr( "List does not exist. Press any key.",
  1613. ***** ^ not supported yet
  1614. ***** ^ not supported yet
  1615. ***** ^ not supported yet
  1616. 649 message );
  1617. ***** ^ not supported yet
  1618. 650 ELSE
  1619. 651 BadFieldNum := 0;
  1620. 652 done := TRUE;
  1621. 653 END;
  1622. 654 END;
  1623. 655 END;
  1624. 656 RETURN done;
  1625. 657 END AllFieldsCorrect;
  1626. ***** ^ not supported yet
  1627. 658
  1628. 659
  1629. 660
  1630. 661 PROCEDURE ToNdxFile();
  1631. 662 VAR
  1632. 663 TmpList1, TmpList2, TmpList3: GenLists.GenList;
  1633. ***** ^ not supported yet
  1634. 664
  1635. 665 PROCEDURE PairFieldNames( list1, list2: GenLists.GenList; VAR
  1636. ***** ^ not supported yet
  1637. 666 outlist: GenLists.GenList);
  1638. ***** ^ not supported yet
  1639. 667 VAR
  1640. 668 lngth1, lngth2, cnt, TypeCode, strndx, spot: CARDINAL;
  1641. 669 TmpStr1, TmpStr2: ARRAY [0..79] OF CHAR;
  1642. ***** ^ not supported yet
  1643. ***** ^ not supported yet
  1644. 670 BEGIN
  1645. 671 lngth1 := GenLists.ListLength( list1 );
  1646. ***** ^ not supported yet
  1647. ***** ^ not supported yet
  1648. ***** ^ not supported yet
  1649. 672 lngth2 := GenLists.ListLength( list2 );
  1650. ***** ^ not supported yet
  1651. ***** ^ not supported yet
  1652. ***** ^ not supported yet
  1653. 673 GenLists.NewList( outlist );
  1654. ***** ^ not supported yet
  1655. ***** ^ not supported yet
  1656. ***** ^ not supported yet
  1657. 674 FOR cnt := 1 TO lngth1 DO
  1658. 675 GenLists.GetElmt( list1, cnt, TmpStr1, TypeCode );
  1659. ***** ^ not supported yet
  1660. ***** ^ not supported yet
  1661. ***** ^ not supported yet
  1662. ***** ^ not supported yet
  1663. ***** ^ not supported yet
  1664. 676 IF TypeCode = GenLists.StrCode THEN
  1665. ***** ^ not supported yet
  1666. ***** ^ not supported yet
  1667. 677 spot := GenLists.ScanList( TmpStr1, list2, 1, lngth2, strndx );
  1668. ***** ^ not supported yet
  1669. ***** ^ not supported yet
  1670. ***** ^ not supported yet
  1671. ***** ^ not supported yet
  1672. ***** ^ not supported yet
  1673. 678 IF (spot > 0) AND (strndx = 0) THEN
  1674. 679 GenLists.GetElmt( list2, spot, TmpStr2, TypeCode );
  1675. ***** ^ not supported yet
  1676. ***** ^ not supported yet
  1677. ***** ^ not supported yet
  1678. ***** ^ not supported yet
  1679. ***** ^ not supported yet
  1680. 680 StrEdit.Append( TmpStr1, '=' );
  1681. ***** ^ not supported yet
  1682. ***** ^ not supported yet
  1683. ***** ^ not supported yet
  1684. ***** ^ not supported yet
  1685. 681 StrEdit.Append( TmpStr1, TmpStr2 );
  1686. ***** ^ not supported yet
  1687. ***** ^ not supported yet
  1688. ***** ^ not supported yet
  1689. ***** ^ not supported yet
  1690. 682 GenLists.ListInsert( TmpStr1, GenLists.StrCode, outlist,
  1691. ***** ^ not supported yet
  1692. ***** ^ not supported yet
  1693. ***** ^ not supported yet
  1694. ***** ^ not supported yet
  1695. ***** ^ not supported yet
  1696. ***** ^ not supported yet
  1697. 683 GenLists.ListLength(outlist) + 1 );
  1698. ***** ^ not supported yet
  1699. ***** ^ not supported yet
  1700. ***** ^ not supported yet
  1701. ***** ^ not supported yet
  1702. 684 END;
  1703. 685 END;
  1704. 686 END;
  1705. 687 END PairFieldNames;
  1706. ***** ^ not supported yet
  1707. 688
  1708. 689 BEGIN (*ToNdxFile*)
  1709. 690 done := AllFieldsCorrect( TmpFrame, 'cpyfname',
  1710. ***** ^ not supported yet
  1711. ***** ^ not supported yet
  1712. ***** ^ not supported yet
  1713. 691 ErrField, message, fname, 'cpylist', RecNameList );
  1714. ***** ^ not supported yet
  1715. ***** ^ not supported yet
  1716. ***** ^ not supported yet
  1717. ***** ^ not supported yet
  1718. 692 StrEdit.CrunchBlanks( fname);
  1719. ***** ^ not supported yet
  1720. ***** ^ not supported yet
  1721. ***** ^ not supported yet
  1722. 693 IF done THEN
  1723. 694 IF PosUtils.Equal( fname, NdxFile^.name) THEN
  1724. ***** ^ not supported yet
  1725. ***** ^ not supported yet
  1726. ***** ^ not supported yet
  1727. ***** ^ not supported yet
  1728. ***** ^ not supported yet
  1729. 695 done := FALSE;
  1730. 696 message := 'Cannot export from a file to itself';
  1731. ***** ^ not supported yet
  1732. ***** ^ not supported yet
  1733. 697 ErrField := 8;
  1734. 698 ELSIF NOT NdxBones.OpenNdxFile( DestNdxFile, fname ) THEN
  1735. ***** ^ not supported yet
  1736. ***** ^ not supported yet
  1737. ***** ^ not supported yet
  1738. ***** ^ not supported yet
  1739. 699 ErrorOpeningFile( StringIO.MissingMessage, 'Not an Index File.',
  1740. ***** ^ not supported yet
  1741. ***** ^ not supported yet
  1742. ***** ^ not supported yet
  1743. ***** ^ not supported yet
  1744. 700 fname );
  1745. ***** ^ not supported yet
  1746. 701 done := FALSE;
  1747. 702 ELSE
  1748. 703 DspFiles.ReadDisplayFrame( ScreenFile, TmpFrame, NextFrame );
  1749. ***** ^ not supported yet
  1750. ***** ^ not supported yet
  1751. ***** ^ not supported yet
  1752. ***** ^ not supported yet
  1753. ***** ^ not supported yet
  1754. 704 IF NOT (0 # ScrnUtl1.FieldNum( TmpFrame,
  1755. ***** ^ not supported yet
  1756. ***** ^ not supported yet
  1757. ***** ^ not supported yet
  1758. 705 'oldstruct' )) THEN
  1759. ***** ^ not supported yet
  1760. 706 HALT();
  1761. ***** ^ undeclared identifier
  1762. ***** ^ not supported yet
  1763. 707 END;
  1764. 708 GenLists.CopyList( NdxFile^.StructLst, TmpList1 );
  1765. ***** ^ not supported yet
  1766. ***** ^ not supported yet
  1767. ***** ^ not supported yet
  1768. ***** ^ not supported yet
  1769. ***** ^ not supported yet
  1770. 709 IF NOT ScrnUtl1.ListToEdField( TmpList1,
  1771. ***** ^ not supported yet
  1772. ***** ^ not supported yet
  1773. ***** ^ not supported yet
  1774. 710 TmpFrame,
  1775. ***** ^ not supported yet
  1776. 711 TmpFrame^.CurrentField ) THEN
  1777. ***** ^ not supported yet
  1778. ***** ^ not supported yet
  1779. 712 HALT();
  1780. ***** ^ undeclared identifier
  1781. ***** ^ not supported yet
  1782. 713 END;
  1783. 714 IF NOT (0 # ScrnUtl1.FieldNum( TmpFrame,
  1784. ***** ^ not supported yet
  1785. ***** ^ not supported yet
  1786. ***** ^ not supported yet
  1787. 715 'newstruct' )) THEN
  1788. ***** ^ not supported yet
  1789. 716 HALT();
  1790. ***** ^ undeclared identifier
  1791. ***** ^ not supported yet
  1792. 717 END;
  1793. 718 GenLists.CopyList( DestNdxFile^.StructLst, TmpList2 );
  1794. ***** ^ not supported yet
  1795. ***** ^ not supported yet
  1796. ***** ^ not supported yet
  1797. ***** ^ not supported yet
  1798. ***** ^ not supported yet
  1799. 719 IF NOT ScrnUtl1.ListToEdField( TmpList2,
  1800. ***** ^ not supported yet
  1801. ***** ^ not supported yet
  1802. ***** ^ not supported yet
  1803. 720 TmpFrame,
  1804. ***** ^ not supported yet
  1805. 721 TmpFrame^.CurrentField ) THEN
  1806. ***** ^ not supported yet
  1807. ***** ^ not supported yet
  1808. 722 HALT();
  1809. ***** ^ undeclared identifier
  1810. ***** ^ not supported yet
  1811. 723 END;
  1812. 724 IF NOT (0 # ScrnUtl1.FieldNum( TmpFrame, 'matches' )) THEN
  1813. ***** ^ not supported yet
  1814. ***** ^ not supported yet
  1815. ***** ^ not supported yet
  1816. ***** ^ not supported yet
  1817. 725 HALT();
  1818. ***** ^ undeclared identifier
  1819. ***** ^ not supported yet
  1820. 726 END;
  1821. 727 PairFieldNames( NdxFile^.StructLst,
  1822. ***** ^ not supported yet
  1823. ***** ^ not supported yet
  1824. ***** ^ not supported yet
  1825. 728 DestNdxFile^.StructLst, MatchingFieldList );
  1826. ***** ^ not supported yet
  1827. ***** ^ not supported yet
  1828. ***** ^ not supported yet
  1829. 729 GenLists.CopyList( MatchingFieldList, TmpList3 );
  1830. ***** ^ not supported yet
  1831. ***** ^ not supported yet
  1832. ***** ^ not supported yet
  1833. ***** ^ not supported yet
  1834. 730 IF NOT ScrnUtl1.ListToEdField( TmpList3,
  1835. ***** ^ not supported yet
  1836. ***** ^ not supported yet
  1837. ***** ^ not supported yet
  1838. 731 TmpFrame, TmpFrame^.CurrentField ) THEN
  1839. ***** ^ not supported yet
  1840. ***** ^ not supported yet
  1841. ***** ^ not supported yet
  1842. 732 HALT();
  1843. ***** ^ undeclared identifier
  1844. ***** ^ not supported yet
  1845. 733 END;
  1846. 734 GenLists.DisposeList( MatchingFieldList );
  1847. ***** ^ not supported yet
  1848. ***** ^ not supported yet
  1849. ***** ^ not supported yet
  1850. 735 (*We dispose here because the editor field now
  1851. 736 has a copy of the list.*)
  1852. 737 FramePainter.ShowDisplayFrame( TmpFrame, 0, 0, 0, 0 );
  1853. ***** ^ not supported yet
  1854. ***** ^ not supported yet
  1855. ***** ^ not supported yet
  1856. ***** ^ not supported yet
  1857. 738 InputManager.ControlFrame( TmpFrame, 0, '', FALSE,
  1858. ***** ^ not supported yet
  1859. ***** ^ not supported yet
  1860. ***** ^ not supported yet
  1861. 739 NextFrame );
  1862. ***** ^ not supported yet
  1863. 740 (*Let them edit the lists.*)
  1864. 741 IF NOT (0 # ScrnUtl1.FieldNum( TmpFrame, 'MATCHES')) THEN
  1865. ***** ^ not supported yet
  1866. ***** ^ not supported yet
  1867. ***** ^ not supported yet
  1868. ***** ^ not supported yet
  1869. 742 HALT();
  1870. ***** ^ undeclared identifier
  1871. ***** ^ not supported yet
  1872. 743 END;
  1873. 744 IF NOT ScrnUtl1.ListFromEdField( TmpFrame,
  1874. ***** ^ not supported yet
  1875. ***** ^ not supported yet
  1876. ***** ^ not supported yet
  1877. 745 TmpFrame^.CurrentField, MatchingFieldList ) THEN
  1878. ***** ^ not supported yet
  1879. ***** ^ not supported yet
  1880. ***** ^ not supported yet
  1881. 746 HALT();
  1882. ***** ^ undeclared identifier
  1883. ***** ^ not supported yet
  1884. 747 END;
  1885. 748 (*Now we've gotten the list back from the editor
  1886. 749 field, presumably changed in some way.*)
  1887. 750 GenLists.CopyList( MatchingFieldList, TmpList1 );
  1888. ***** ^ not supported yet
  1889. ***** ^ not supported yet
  1890. ***** ^ not supported yet
  1891. ***** ^ not supported yet
  1892. 751 IF PosUtils.Equal( NextFrame, TmpFrame^.normlnext ) THEN
  1893. ***** ^ not supported yet
  1894. ***** ^ not supported yet
  1895. ***** ^ not supported yet
  1896. ***** ^ not supported yet
  1897. ***** ^ not supported yet
  1898. 752 ExportToNdxFile( NdxFile, RecNameList,
  1899. ***** ^ not supported yet
  1900. ***** ^ not supported yet
  1901. ***** ^ not supported yet
  1902. 753 TmpList1, DestNdxFile );
  1903. ***** ^ not supported yet
  1904. ***** ^ not supported yet
  1905. 754 NextFrame := '24';
  1906. ***** ^ not supported yet
  1907. ***** ^ not supported yet
  1908. 755 END;
  1909. 756 NdxFiles.CloseNdxFile( DestNdxFile );
  1910. ***** ^ not supported yet
  1911. ***** ^ not supported yet
  1912. ***** ^ not supported yet
  1913. 757 END;
  1914. 758 END;
  1915. 759 END ToNdxFile;
  1916. ***** ^ not supported yet
  1917. 760
  1918. 761 PROCEDURE ToAscii();
  1919. 762 BEGIN
  1920. 763 IF AllFieldsCorrect( TmpFrame, 'expfname',
  1921. ***** ^ not supported yet
  1922. ***** ^ not supported yet
  1923. ***** ^ not supported yet
  1924. 764 ErrField, message, fname, 'explist', RecNameList ) THEN
  1925. ***** ^ not supported yet
  1926. ***** ^ not supported yet
  1927. ***** ^ not supported yet
  1928. ***** ^ not supported yet
  1929. 765 IF NotPmiFile( fname) THEN
  1930. ***** ^ not supported yet
  1931. ***** ^ not supported yet
  1932. 766 SavedMessage := HandleIO.CreateFile( ExpFile, fname );
  1933. ***** ^ not supported yet
  1934. ***** ^ not supported yet
  1935. ***** ^ not supported yet
  1936. 767 IF SavedMessage = StringIO.NoError THEN
  1937. ***** ^ not supported yet
  1938. ***** ^ not supported yet
  1939. 768 ScrnUtl2.ReadAndShow( ScreenFile, TmpFrame, '38' );
  1940. ***** ^ not supported yet
  1941. ***** ^ not supported yet
  1942. ***** ^ not supported yet
  1943. ***** ^ not supported yet
  1944. ***** ^ not supported yet
  1945. 769 NdxUtils.ExportToFile( NdxFile, RecNameList, ExpFile );
  1946. ***** ^ not supported yet
  1947. ***** ^ not supported yet
  1948. ***** ^ not supported yet
  1949. ***** ^ not supported yet
  1950. ***** ^ not supported yet
  1951. 770 StringIO.PrintMessage( HandleIO.CloseHandle( ExpFile ) );
  1952. ***** ^ not supported yet
  1953. ***** ^ not supported yet
  1954. ***** ^ not supported yet
  1955. ***** ^ not supported yet
  1956. ***** ^ not supported yet
  1957. 771 NextFrame := '24';
  1958. ***** ^ not supported yet
  1959. ***** ^ not supported yet
  1960. 772 done := TRUE;
  1961. 773 ELSE
  1962. 774 ErrorOpeningFile( SavedMessage, '', fname );
  1963. ***** ^ not supported yet
  1964. ***** ^ not supported yet
  1965. 775 done := FALSE;
  1966. 776 END;
  1967. 777 ELSE
  1968. 778 ErrorOpeningFile( StringIO.MissingMessage,
  1969. ***** ^ not supported yet
  1970. ***** ^ not supported yet
  1971. ***** ^ not supported yet
  1972. 779 'Invalid Reserved PMI File Name', fname );
  1973. ***** ^ not supported yet
  1974. ***** ^ not supported yet
  1975. 780 done := FALSE;
  1976. 781 END;
  1977. 782 END;
  1978. 783 END ToAscii;
  1979. ***** ^ not supported yet
  1980. 784
  1981. 785 PROCEDURE ToPrinter();
  1982. 786 BEGIN
  1983. 787 done := AllFieldsCorrect( TmpFrame, 'prnlist',
  1984. ***** ^ not supported yet
  1985. ***** ^ not supported yet
  1986. ***** ^ not supported yet
  1987. 788 ErrField, message, fname, 'prnlist', RecNameList );
  1988. ***** ^ not supported yet
  1989. ***** ^ not supported yet
  1990. ***** ^ not supported yet
  1991. ***** ^ not supported yet
  1992. 789 IF done THEN
  1993. 790 ScrnUtl2.ReadAndShow( ScreenFile, TmpFrame, '38' );
  1994. ***** ^ not supported yet
  1995. ***** ^ not supported yet
  1996. ***** ^ not supported yet
  1997. ***** ^ not supported yet
  1998. ***** ^ not supported yet
  1999. 791 NdxUtils.ExportToFile( NdxFile, RecNameList, StringIO.StdPrn );
  2000. ***** ^ not supported yet
  2001. ***** ^ not supported yet
  2002. ***** ^ not supported yet
  2003. ***** ^ not supported yet
  2004. ***** ^ not supported yet
  2005. ***** ^ not supported yet
  2006. 792 NextFrame := '37';
  2007. ***** ^ not supported yet
  2008. ***** ^ not supported yet
  2009. 793 END;
  2010. 794 END ToPrinter;
  2011. ***** ^ not supported yet
  2012. 795
  2013. 796
  2014. 797 BEGIN (*ExportRecords*)
  2015. 798 ScrnTypes.InitDisplayFrame( TmpFrame, VWindows.CurrentWindow );
  2016. ***** ^ not supported yet
  2017. ***** ^ not supported yet
  2018. ***** ^ not supported yet
  2019. ***** ^ not supported yet
  2020. ***** ^ not supported yet
  2021. 799 NextFrame := '19';
  2022. ***** ^ not supported yet
  2023. ***** ^ not supported yet
  2024. 800 (*This is the export form; the one with all the lines
  2025. 801 and blanks for list and file names.*)
  2026. 802 ScrnUtl2.ReadAndShow( ScreenFile, TmpFrame, NextFrame );
  2027. ***** ^ not supported yet
  2028. ***** ^ not supported yet
  2029. ***** ^ not supported yet
  2030. ***** ^ not supported yet
  2031. ***** ^ not supported yet
  2032. 803 done := FALSE;
  2033. 804 ErrField := 0;
  2034. 805 StrEdit.AssignStr( '', message );
  2035. ***** ^ not supported yet
  2036. ***** ^ not supported yet
  2037. ***** ^ not supported yet
  2038. 806 StrEdit.AssignStr( '', fname );
  2039. ***** ^ not supported yet
  2040. ***** ^ not supported yet
  2041. ***** ^ not supported yet
  2042. 807 WHILE NOT done DO
  2043. 808 InputManager.ControlFrame( TmpFrame, ErrField,
  2044. ***** ^ not supported yet
  2045. ***** ^ not supported yet
  2046. ***** ^ not supported yet
  2047. 809 message, FALSE, NextFrame );
  2048. ***** ^ not supported yet
  2049. ***** ^ not supported yet
  2050. 810 IF PosUtils.Equal( NextFrame, TmpFrame^.parent ) THEN
  2051. ***** ^ not supported yet
  2052. ***** ^ not supported yet
  2053. ***** ^ not supported yet
  2054. ***** ^ not supported yet
  2055. ***** ^ not supported yet
  2056. 811 RETURN;
  2057. 812 END;
  2058. 813 CASE ScrnUtl1.SelectedChar(TmpFrame) OF
  2059. ***** ^ not supported yet
  2060. ***** ^ not supported yet
  2061. ***** ^ not supported yet
  2062. 814 (*To determine what they want us to do, we have to
  2063. 815 figure out where the pointer bar was when the
  2064. 816 screen was submitted.*)
  2065. 817 'A', 'l', 'f':
  2066. 818 (*Export records to an ASCII file.*)
  2067. 819 ToAscii();
  2068. ***** ^ not supported yet
  2069. ***** ^ not supported yet
  2070. 820 | 'P', 'p': (*Print records.*)
  2071. 821 ToPrinter();
  2072. ***** ^ not supported yet
  2073. ***** ^ not supported yet
  2074. 822 | 'N', 'c', 'x': (*Copy records to another Ndx file.*)
  2075. 823 ToNdxFile();
  2076. ***** ^ not supported yet
  2077. ***** ^ not supported yet
  2078. 824 END;
  2079. 825 END; (*WHILE NOT done*)
  2080. 826 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  2081. ***** ^ not supported yet
  2082. ***** ^ not supported yet
  2083. ***** ^ not supported yet
  2084. 827 END ExportRecords;
  2085. ***** ^ not supported yet
  2086. 828
  2087. 829
  2088. 830 PROCEDURE GetFile( VAR NdxFile: NdxTypes.NdxFileType; ScreenFile:
  2089. ***** ^ not supported yet
  2090. 831 ScrnTypes.DisplayFile; VAR NextFrame: ScrnTypes.AFrameName): BOOLEAN;
  2091. ***** ^ not supported yet
  2092. ***** ^ not supported yet
  2093. 832 VAR
  2094. 833 SavedMessage : CARDINAL;
  2095. 834 SelectedFile, FileSpec: ARRAY [0..79] OF CHAR;
  2096. ***** ^ not supported yet
  2097. ***** ^ not supported yet
  2098. 835 FileOpened, dumbool: BOOLEAN;
  2099. 836 structure: ARRAY [0..511] OF CHAR;
  2100. ***** ^ not supported yet
  2101. ***** ^ not supported yet
  2102. 837 pathleng, KeyHit: CARDINAL;
  2103. 838 TmpFrame: ScrnTypes.DisplayFrame;
  2104. ***** ^ not supported yet
  2105. 839
  2106. 840 PROCEDURE OpenExisting( fname: ARRAY OF CHAR ): BOOLEAN;
  2107. ***** ^ not supported yet
  2108. 841 BEGIN
  2109. 842 IF FileOpened THEN
  2110. 843 NdxFiles.CloseNdxFile( NdxFile );
  2111. ***** ^ not supported yet
  2112. ***** ^ not supported yet
  2113. ***** ^ not supported yet
  2114. 844 END;
  2115. 845 IF NOT NdxBones.OpenNdxFile( NdxFile, fname ) THEN
  2116. ***** ^ not supported yet
  2117. ***** ^ not supported yet
  2118. ***** ^ not supported yet
  2119. ***** ^ not supported yet
  2120. 846 ErrorOpeningFile( StringIO.MissingMessage, 'Not an Index File.',
  2121. ***** ^ not supported yet
  2122. ***** ^ not supported yet
  2123. ***** ^ not supported yet
  2124. ***** ^ not supported yet
  2125. 847 fname );
  2126. ***** ^ not supported yet
  2127. 848 RETURN FALSE;
  2128. 849 ELSE
  2129. 850 WindowPrims.MsgBox( VWindows.SE,
  2130. ***** ^ not supported yet
  2131. ***** ^ not supported yet
  2132. ***** ^ not supported yet
  2133. ***** ^ not supported yet
  2134. 851 'New file selected. Press any key.',
  2135. ***** ^ not supported yet
  2136. 852 KbdInput.AnyKeyNum, KeyHit );
  2137. ***** ^ not supported yet
  2138. ***** ^ not supported yet
  2139. ***** ^ not supported yet
  2140. 853 NextFrame := '2';
  2141. ***** ^ not supported yet
  2142. 854 (*We do this to guarantee that we fall out at the
  2143. 855 bottom of the loop.*)
  2144. 856 RETURN TRUE;
  2145. 857 END;
  2146. 858 END OpenExisting;
  2147. ***** ^ not supported yet
  2148. 859
  2149. 860 PROCEDURE TryCreate();
  2150. 861
  2151. 862 BEGIN (* TryCreate *)
  2152. 863 IF NotPmiFile( FileSpec ) THEN
  2153. ***** ^ not supported yet
  2154. ***** ^ not supported yet
  2155. 864 IF Drectory.ValidFile( FileSpec ) THEN
  2156. ***** ^ not supported yet
  2157. ***** ^ not supported yet
  2158. ***** ^ not supported yet
  2159. 865 WindowPrims.MsgBox( VWindows.SE,
  2160. ***** ^ not supported yet
  2161. ***** ^ not supported yet
  2162. ***** ^ not supported yet
  2163. ***** ^ not supported yet
  2164. 866 "File not found. Do you want to create it? (Y/N)",
  2165. ***** ^ not supported yet
  2166. 867 KbdInput.YorN, KeyHit );
  2167. ***** ^ not supported yet
  2168. ***** ^ not supported yet
  2169. ***** ^ not supported yet
  2170. 868 IF KbdInput.CAPkey(KeyHit) = ORD('Y') THEN
  2171. ***** ^ not supported yet
  2172. ***** ^ not supported yet
  2173. ***** ^ not supported yet
  2174. ***** ^ undeclared identifier
  2175. ***** ^ not supported yet
  2176. 869 IF FileOpened THEN
  2177. 870 NdxFiles.CloseNdxFile( NdxFile );
  2178. ***** ^ not supported yet
  2179. ***** ^ not supported yet
  2180. ***** ^ not supported yet
  2181. 871 END;
  2182. 872 (*For convenience we've stored the file structure in
  2183. 873 the DataList for frame 6.*)
  2184. 874 ListUtils.ListToString( TmpFrame^.DataList, structure );
  2185. ***** ^ not supported yet
  2186. ***** ^ not supported yet
  2187. ***** ^ not supported yet
  2188. ***** ^ not supported yet
  2189. ***** ^ not supported yet
  2190. 875 NdxFiles.CreateNdxFile( NdxFile, FileSpec, structure );
  2191. ***** ^ not supported yet
  2192. ***** ^ not supported yet
  2193. ***** ^ not supported yet
  2194. ***** ^ not supported yet
  2195. ***** ^ not supported yet
  2196. 876 WindowPrims.MsgBox( VWindows.SE,
  2197. ***** ^ not supported yet
  2198. ***** ^ not supported yet
  2199. ***** ^ not supported yet
  2200. ***** ^ not supported yet
  2201. 877 'File created. Press any key.', KbdInput.AnyKeyNum,
  2202. ***** ^ not supported yet
  2203. ***** ^ not supported yet
  2204. ***** ^ not supported yet
  2205. 878 KeyHit );
  2206. ***** ^ not supported yet
  2207. 879 FileOpened := TRUE;
  2208. 880 END;
  2209. 881 ELSE
  2210. 882 ErrorOpeningFile( StringIO.MissingMessage,
  2211. ***** ^ not supported yet
  2212. ***** ^ not supported yet
  2213. ***** ^ not supported yet
  2214. 883 'Invalid File Name', FileSpec );
  2215. ***** ^ not supported yet
  2216. ***** ^ not supported yet
  2217. 884 END;
  2218. 885 ELSE
  2219. 886 ErrorOpeningFile( StringIO.MissingMessage,
  2220. ***** ^ not supported yet
  2221. ***** ^ not supported yet
  2222. ***** ^ not supported yet
  2223. 887 'Invalid Reserved PMI File Name', FileSpec );
  2224. ***** ^ not supported yet
  2225. ***** ^ not supported yet
  2226. 888 END;
  2227. 889 END TryCreate;
  2228. ***** ^ not supported yet
  2229. 890
  2230. 891 BEGIN
  2231. 892 (*GetFile*)
  2232. 893 FileOpened := FALSE;
  2233. 894 ScrnTypes.InitDisplayFrame( TmpFrame, VWindows.CurrentWindow );
  2234. ***** ^ not supported yet
  2235. ***** ^ not supported yet
  2236. ***** ^ not supported yet
  2237. ***** ^ not supported yet
  2238. ***** ^ not supported yet
  2239. 895 REPEAT
  2240. 896 NextFrame := '6';
  2241. ***** ^ not supported yet
  2242. 897 (*File Creation/Selection form; prompts for a file
  2243. 898 specification*)
  2244. 899 ControlUtils.ReadShowAndCntrl( ScreenFile, TmpFrame, NextFrame );
  2245. ***** ^ not supported yet
  2246. ***** ^ not supported yet
  2247. ***** ^ not supported yet
  2248. ***** ^ not supported yet
  2249. ***** ^ not supported yet
  2250. 900 IF NOT PosUtils.Equal( NextFrame, TmpFrame^.normlnext ) THEN
  2251. ***** ^ not supported yet
  2252. ***** ^ not supported yet
  2253. ***** ^ not supported yet
  2254. ***** ^ not supported yet
  2255. ***** ^ not supported yet
  2256. 901 (*return if they press the backup key*)
  2257. 902 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  2258. ***** ^ not supported yet
  2259. ***** ^ not supported yet
  2260. ***** ^ not supported yet
  2261. 903 RETURN FileOpened;
  2262. 904 END;
  2263. 905 ControlUtils.ReadInput( TmpFrame, FileSpec, 'path');
  2264. ***** ^ not supported yet
  2265. ***** ^ not supported yet
  2266. ***** ^ not supported yet
  2267. ***** ^ not supported yet
  2268. ***** ^ not supported yet
  2269. 906 (*Get the string out of the field named 'path' and put
  2270. 907 it in the variable FileSpec.*)
  2271. 908 StrEdit.CutTrailingChars( ' ', FileSpec);
  2272. ***** ^ not supported yet
  2273. ***** ^ not supported yet
  2274. ***** ^ not supported yet
  2275. 909 pathleng := M2Strings.Length(FileSpec);
  2276. ***** ^ not supported yet
  2277. ***** ^ not supported yet
  2278. ***** ^ not supported yet
  2279. 910 IF HandleIO.FileExists( FileSpec ) THEN
  2280. ***** ^ not supported yet
  2281. ***** ^ not supported yet
  2282. ***** ^ not supported yet
  2283. 911 (* open file entered *)
  2284. 912 FileOpened := OpenExisting( FileSpec );
  2285. ***** ^ not supported yet
  2286. ***** ^ not supported yet
  2287. 913 ELSIF (pathleng > 0) AND
  2288. 914 (NOT PosUtils.Present( '*', FileSpec)) AND
  2289. ***** ^ not supported yet
  2290. ***** ^ not supported yet
  2291. ***** ^ not supported yet
  2292. 915 (FileSpec[ pathleng-1] # '\') AND
  2293. ***** ^ not supported yet
  2294. ***** ^ not supported yet
  2295. 916 (FileSpec[ pathleng-1] # ':') THEN
  2296. ***** ^ not supported yet
  2297. ***** ^ not supported yet
  2298. 917 (* try to create file name entered *)
  2299. 918 TryCreate();
  2300. ***** ^ not supported yet
  2301. ***** ^ not supported yet
  2302. 919 ELSE
  2303. 920 (* search for file spec entered *)
  2304. 921 ScrnUtl2.PushFrame( TmpFrame );
  2305. ***** ^ not supported yet
  2306. ***** ^ not supported yet
  2307. ***** ^ not supported yet
  2308. 922 (*this saves frame 6*)
  2309. 923 NextFrame := '7';
  2310. ***** ^ not supported yet
  2311. 924 (*7 is a blank window to hold the file names*)
  2312. 925 DspFiles.ReadDisplayFrame( ScreenFile, TmpFrame, NextFrame );
  2313. ***** ^ not supported yet
  2314. ***** ^ not supported yet
  2315. ***** ^ not supported yet
  2316. ***** ^ not supported yet
  2317. ***** ^ not supported yet
  2318. 926 DirManager.ControlDirectory( FileSpec,
  2319. ***** ^ not supported yet
  2320. ***** ^ not supported yet
  2321. ***** ^ not supported yet
  2322. 927 TmpFrame, 1, SelectedFile, NextFrame );
  2323. ***** ^ not supported yet
  2324. ***** ^ not supported yet
  2325. ***** ^ not supported yet
  2326. 928 (*Loads frame 7 with a list of filenames that match
  2327. 929 the file specification in FileSpec, and controls
  2328. 930 scrolling of the pointer bar within the frame until
  2329. 931 the user selects a file. The 1 means
  2330. 932 ControlDirectory will list only file NAMES (i.e.,
  2331. 933 will use only one column). We could have it list
  2332. 934 size, date, and time information by using 2, 3, or
  2333. 935 4 for the number of columns. *)
  2334. 936 IF PosUtils.Equal( NextFrame, TmpFrame^.normlnext ) THEN
  2335. ***** ^ not supported yet
  2336. ***** ^ not supported yet
  2337. ***** ^ not supported yet
  2338. ***** ^ not supported yet
  2339. ***** ^ not supported yet
  2340. 937 StrEdit.DeleteChar( ' ', SelectedFile );
  2341. ***** ^ not supported yet
  2342. ***** ^ not supported yet
  2343. ***** ^ not supported yet
  2344. 938 IF NOT PosUtils.Present( 'Error:', SelectedFile ) THEN
  2345. ***** ^ not supported yet
  2346. ***** ^ not supported yet
  2347. ***** ^ not supported yet
  2348. ***** ^ not supported yet
  2349. 939 FileOpened := OpenExisting( SelectedFile );
  2350. ***** ^ not supported yet
  2351. ***** ^ not supported yet
  2352. 940 ScrnUtl2.PopFrame( TmpFrame );
  2353. ***** ^ not supported yet
  2354. ***** ^ not supported yet
  2355. ***** ^ not supported yet
  2356. 941 (*TmpFrame is now frame 6.*)
  2357. 942 ELSE
  2358. 943 (* couldn't search for file, so try to create it *)
  2359. 944 ScrnUtl2.PopFrame( TmpFrame );
  2360. ***** ^ not supported yet
  2361. ***** ^ not supported yet
  2362. ***** ^ not supported yet
  2363. 945 (*TmpFrame is now frame 6.*)
  2364. 946 TryCreate();
  2365. ***** ^ not supported yet
  2366. ***** ^ not supported yet
  2367. 947 END;
  2368. 948 ELSE
  2369. 949 ScrnUtl2.PopFrame( TmpFrame );
  2370. ***** ^ not supported yet
  2371. ***** ^ not supported yet
  2372. ***** ^ not supported yet
  2373. 950 (*TmpFrame is now frame 6.*)
  2374. 951 END;
  2375. 952 END;
  2376. 953 UNTIL FileOpened;
  2377. 954 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  2378. ***** ^ not supported yet
  2379. ***** ^ not supported yet
  2380. ***** ^ not supported yet
  2381. 955 RETURN FileOpened;
  2382. 956 END GetFile;
  2383. ***** ^ not supported yet
  2384. 957
  2385. 958
  2386. 959 PROCEDURE FileManagement( VAR NdxFile: NdxTypes.NdxFileType; VAR NextFrame:
  2387. ***** ^ not supported yet
  2388. 960 ScrnTypes.AFrameName; ScreenFile: ScrnTypes.DisplayFile);
  2389. ***** ^ not supported yet
  2390. ***** ^ not supported yet
  2391. 961
  2392. 962 PROCEDURE CrunchMenu();
  2393. 963 VAR
  2394. 964 TotSize, GbgSize: LONGINT;
  2395. 965 PctUsed, NumDatRecs, NumGbgRecs: CARDINAL;
  2396. 966 dumstr: ARRAY [0..80] OF CHAR;
  2397. ***** ^ not supported yet
  2398. ***** ^ not supported yet
  2399. 967 TmpFrame: ScrnTypes.DisplayFrame;
  2400. ***** ^ not supported yet
  2401. 968 BEGIN
  2402. 969 ScrnTypes.InitDisplayFrame( TmpFrame, VWindows.CurrentWindow );
  2403. ***** ^ not supported yet
  2404. ***** ^ not supported yet
  2405. ***** ^ not supported yet
  2406. ***** ^ not supported yet
  2407. ***** ^ not supported yet
  2408. 970 REPEAT
  2409. 971 NextFrame := '10';
  2410. ***** ^ not supported yet
  2411. ***** ^ not supported yet
  2412. 972 DspFiles.ReadDisplayFrame( ScreenFile, TmpFrame, NextFrame );
  2413. ***** ^ not supported yet
  2414. ***** ^ not supported yet
  2415. ***** ^ not supported yet
  2416. ***** ^ not supported yet
  2417. ***** ^ not supported yet
  2418. 973 NdxUtils.SizeInfo( NdxFile, TotSize, GbgSize, PctUsed, NumDatRecs,
  2419. ***** ^ not supported yet
  2420. ***** ^ not supported yet
  2421. ***** ^ not supported yet
  2422. 974 NumGbgRecs);
  2423. ***** ^ not supported yet
  2424. 975 StrConv.LongIntegerToStr( TotSize, 0, dumstr);
  2425. ***** ^ not supported yet
  2426. ***** ^ not supported yet
  2427. ***** ^ not supported yet
  2428. 976 ControlUtils.ChangeField( TmpFrame, dumstr, 'size', FALSE );
  2429. ***** ^ not supported yet
  2430. ***** ^ not supported yet
  2431. ***** ^ not supported yet
  2432. ***** ^ not supported yet
  2433. ***** ^ not supported yet
  2434. ***** ^ not supported yet
  2435. 977 StrConv.LongIntegerToStr( GbgSize, 0, dumstr);
  2436. ***** ^ not supported yet
  2437. ***** ^ not supported yet
  2438. ***** ^ not supported yet
  2439. 978 ControlUtils.ChangeField( TmpFrame, dumstr, 'save', FALSE );
  2440. ***** ^ not supported yet
  2441. ***** ^ not supported yet
  2442. ***** ^ not supported yet
  2443. ***** ^ not supported yet
  2444. ***** ^ not supported yet
  2445. ***** ^ not supported yet
  2446. 979 StrConv.CardinalToStr( PctUsed, 0, dumstr);
  2447. ***** ^ not supported yet
  2448. ***** ^ not supported yet
  2449. ***** ^ not supported yet
  2450. 980 ControlUtils.ChangeField( TmpFrame, dumstr, 'pct', FALSE );
  2451. ***** ^ not supported yet
  2452. ***** ^ not supported yet
  2453. ***** ^ not supported yet
  2454. ***** ^ not supported yet
  2455. ***** ^ not supported yet
  2456. ***** ^ not supported yet
  2457. 981 StrConv.CardinalToStr( NumDatRecs, 0, dumstr);
  2458. ***** ^ not supported yet
  2459. ***** ^ not supported yet
  2460. ***** ^ not supported yet
  2461. 982 ControlUtils.ChangeField( TmpFrame, dumstr, 'custs', FALSE );
  2462. ***** ^ not supported yet
  2463. ***** ^ not supported yet
  2464. ***** ^ not supported yet
  2465. ***** ^ not supported yet
  2466. ***** ^ not supported yet
  2467. ***** ^ not supported yet
  2468. 983 StrConv.CardinalToStr( NumGbgRecs, 0, dumstr);
  2469. ***** ^ not supported yet
  2470. ***** ^ not supported yet
  2471. ***** ^ not supported yet
  2472. 984 ControlUtils.ChangeField( TmpFrame, dumstr, 'grecs', FALSE );
  2473. ***** ^ not supported yet
  2474. ***** ^ not supported yet
  2475. ***** ^ not supported yet
  2476. ***** ^ not supported yet
  2477. ***** ^ not supported yet
  2478. ***** ^ not supported yet
  2479. 985 FramePainter.ShowDisplayFrame( TmpFrame, 0, 0, 0, 0 );
  2480. ***** ^ not supported yet
  2481. ***** ^ not supported yet
  2482. ***** ^ not supported yet
  2483. ***** ^ not supported yet
  2484. 986 InputManager.ControlFrame( TmpFrame, 0, '', FALSE,
  2485. ***** ^ not supported yet
  2486. ***** ^ not supported yet
  2487. ***** ^ not supported yet
  2488. 987 NextFrame );
  2489. ***** ^ not supported yet
  2490. 988 IF PosUtils.Equal( NextFrame, '12' ) THEN
  2491. ***** ^ not supported yet
  2492. ***** ^ not supported yet
  2493. ***** ^ not supported yet
  2494. ***** ^ not supported yet
  2495. 989 ScrnUtl2.ReadAndShow( ScreenFile, TmpFrame, NextFrame );
  2496. ***** ^ not supported yet
  2497. ***** ^ not supported yet
  2498. ***** ^ not supported yet
  2499. ***** ^ not supported yet
  2500. ***** ^ not supported yet
  2501. 990 (*File crunch in progress*)
  2502. 991 NdxUtils.CrunchNdxFile( NdxFile);
  2503. ***** ^ not supported yet
  2504. ***** ^ not supported yet
  2505. ***** ^ not supported yet
  2506. 992 NextFrame := '13'; (*File crunch complete*)
  2507. ***** ^ not supported yet
  2508. ***** ^ not supported yet
  2509. 993 ControlUtils.ReadShowAndCntrl( ScreenFile, TmpFrame, NextFrame );
  2510. ***** ^ not supported yet
  2511. ***** ^ not supported yet
  2512. ***** ^ not supported yet
  2513. ***** ^ not supported yet
  2514. ***** ^ not supported yet
  2515. 994 END;
  2516. 995 UNTIL PosUtils.Equal( NextFrame, TmpFrame^.parent );
  2517. ***** ^ not supported yet
  2518. ***** ^ not supported yet
  2519. ***** ^ not supported yet
  2520. ***** ^ not supported yet
  2521. ***** ^ not supported yet
  2522. 996 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  2523. ***** ^ not supported yet
  2524. ***** ^ not supported yet
  2525. ***** ^ not supported yet
  2526. 997 END CrunchMenu;
  2527. ***** ^ not supported yet
  2528. 998
  2529. 999
  2530. 1000 PROCEDURE EditFile();
  2531. 1001 VAR
  2532. 1002 fname: ARRAY [0..79] OF CHAR;
  2533. ***** ^ not supported yet
  2534. ***** ^ not supported yet
  2535. 1003 ready: BOOLEAN;
  2536. 1004 SavedMessage: CARDINAL;
  2537. 1005 KeyHit: CARDINAL;
  2538. 1006 TheList: GenLists.GenList;
  2539. ***** ^ not supported yet
  2540. 1007 ControlRec: VEditor.AnEdControlRec;
  2541. ***** ^ not supported yet
  2542. 1008 TmpFrame: ScrnTypes.DisplayFrame;
  2543. ***** ^ not supported yet
  2544. 1009
  2545. 1010 BEGIN
  2546. 1011 ScrnTypes.InitDisplayFrame( TmpFrame, VWindows.CurrentWindow );
  2547. ***** ^ not supported yet
  2548. ***** ^ not supported yet
  2549. ***** ^ not supported yet
  2550. ***** ^ not supported yet
  2551. ***** ^ not supported yet
  2552. 1012 ScrnUtl2.ReadAndShow( ScreenFile, TmpFrame, '18' );
  2553. ***** ^ not supported yet
  2554. ***** ^ not supported yet
  2555. ***** ^ not supported yet
  2556. ***** ^ not supported yet
  2557. ***** ^ not supported yet
  2558. 1013 (*This frame prompts for a file name.*)
  2559. 1014 REPEAT
  2560. 1015 InputManager.ControlFrame( TmpFrame, 0, '', FALSE,
  2561. ***** ^ not supported yet
  2562. ***** ^ not supported yet
  2563. ***** ^ not supported yet
  2564. 1016 NextFrame );
  2565. ***** ^ not supported yet
  2566. 1017 IF NOT PosUtils.Equal( NextFrame, TmpFrame^.normlnext ) THEN
  2567. ***** ^ not supported yet
  2568. ***** ^ not supported yet
  2569. ***** ^ not supported yet
  2570. ***** ^ not supported yet
  2571. ***** ^ not supported yet
  2572. 1018 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  2573. ***** ^ not supported yet
  2574. ***** ^ not supported yet
  2575. ***** ^ not supported yet
  2576. 1019 RETURN;
  2577. 1020 END;
  2578. 1021 ControlUtils.ReadInput( TmpFrame, fname, 'fname' );
  2579. ***** ^ not supported yet
  2580. ***** ^ not supported yet
  2581. ***** ^ not supported yet
  2582. ***** ^ not supported yet
  2583. ***** ^ not supported yet
  2584. 1022 (*Get the file name out of the 'fname' field.*)
  2585. 1023 IF NotPmiFile( fname) THEN
  2586. ***** ^ not supported yet
  2587. ***** ^ not supported yet
  2588. 1024 GenLists.NewList( TheList );
  2589. ***** ^ not supported yet
  2590. ***** ^ not supported yet
  2591. ***** ^ not supported yet
  2592. 1025 SavedMessage := ListUtils.TextFileToList( fname, TheList );
  2593. ***** ^ not supported yet
  2594. ***** ^ not supported yet
  2595. ***** ^ not supported yet
  2596. ***** ^ not supported yet
  2597. 1026 IF SavedMessage = StringIO.NoError THEN
  2598. ***** ^ not supported yet
  2599. ***** ^ not supported yet
  2600. 1027 ready := TRUE;
  2601. 1028 ELSIF SavedMessage = StringIO.FileNotFound THEN
  2602. ***** ^ not supported yet
  2603. ***** ^ not supported yet
  2604. 1029 WindowPrims.MsgBox( VWindows.SE,
  2605. ***** ^ not supported yet
  2606. ***** ^ not supported yet
  2607. ***** ^ not supported yet
  2608. ***** ^ not supported yet
  2609. 1030 "File not found. Do you want to create it? (Y/N)",
  2610. ***** ^ not supported yet
  2611. 1031 KbdInput.YorN, KeyHit );
  2612. ***** ^ not supported yet
  2613. ***** ^ not supported yet
  2614. ***** ^ not supported yet
  2615. 1032 ready := KbdInput.CAPkey(KeyHit) = ORD('Y');
  2616. ***** ^ not supported yet
  2617. ***** ^ not supported yet
  2618. ***** ^ not supported yet
  2619. ***** ^ undeclared identifier
  2620. ***** ^ not supported yet
  2621. 1033 IF ready THEN
  2622. 1034 GenLists.NewList( TheList );
  2623. ***** ^ not supported yet
  2624. ***** ^ not supported yet
  2625. ***** ^ not supported yet
  2626. 1035 END;
  2627. 1036 ELSE
  2628. 1037 ErrorOpeningFile( SavedMessage, '', fname );
  2629. ***** ^ not supported yet
  2630. ***** ^ not supported yet
  2631. 1038 ready := FALSE;
  2632. 1039 END;
  2633. 1040 ELSE
  2634. 1041 ErrorOpeningFile( StringIO.MissingMessage,
  2635. ***** ^ not supported yet
  2636. ***** ^ not supported yet
  2637. ***** ^ not supported yet
  2638. 1042 'Invalid Reserved PMI File Name', fname );
  2639. ***** ^ not supported yet
  2640. ***** ^ not supported yet
  2641. 1043 ready := FALSE;
  2642. 1044 END;
  2643. 1045 UNTIL ready;
  2644. 1046 VEditor.InitEdRec( ControlRec );
  2645. ***** ^ not supported yet
  2646. ***** ^ not supported yet
  2647. ***** ^ not supported yet
  2648. 1047 VEditor.TheEditor( TheList, ControlRec );
  2649. ***** ^ not supported yet
  2650. ***** ^ not supported yet
  2651. ***** ^ not supported yet
  2652. ***** ^ not supported yet
  2653. 1048 IF ControlRec.ChangeMade THEN
  2654. ***** ^ not supported yet
  2655. ***** ^ not supported yet
  2656. 1049 (*Ask if they want to save the file.*)
  2657. 1050 WindowPrims.MsgBox( VWindows.SE,
  2658. ***** ^ not supported yet
  2659. ***** ^ not supported yet
  2660. ***** ^ not supported yet
  2661. ***** ^ not supported yet
  2662. 1051 "Do you want to save your changes? (Y/N)",
  2663. ***** ^ not supported yet
  2664. 1052 KbdInput.YorN, KeyHit );
  2665. ***** ^ not supported yet
  2666. ***** ^ not supported yet
  2667. ***** ^ not supported yet
  2668. 1053 ready := KbdInput.CAPkey(KeyHit) = ORD('Y');
  2669. ***** ^ not supported yet
  2670. ***** ^ not supported yet
  2671. ***** ^ not supported yet
  2672. ***** ^ undeclared identifier
  2673. ***** ^ not supported yet
  2674. 1054 IF ready THEN
  2675. 1055 SavedMessage := ListUtils.TextListToFile( TheList, fname );
  2676. ***** ^ not supported yet
  2677. ***** ^ not supported yet
  2678. ***** ^ not supported yet
  2679. ***** ^ not supported yet
  2680. 1056 END;
  2681. 1057 END;
  2682. 1058 GenLists.DisposeList( TheList );
  2683. ***** ^ not supported yet
  2684. ***** ^ not supported yet
  2685. ***** ^ not supported yet
  2686. 1059 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  2687. ***** ^ not supported yet
  2688. ***** ^ not supported yet
  2689. ***** ^ not supported yet
  2690. 1060 END EditFile;
  2691. ***** ^ not supported yet
  2692. 1061
  2693. 1062 PROCEDURE GetRecDate( NdxFile: NdxTypes.NdxFileType;
  2694. ***** ^ not supported yet
  2695. 1063 RecName: ARRAY OF CHAR; VAR Date: CARDINAL );
  2696. ***** ^ not supported yet
  2697. 1064 VAR
  2698. 1065 TypeCode, day, month, year, hours, minutes, seconds: CARDINAL;
  2699. 1066 DateStr: ARRAY [0..31] OF CHAR;
  2700. ***** ^ not supported yet
  2701. ***** ^ not supported yet
  2702. 1067 BEGIN
  2703. 1068 Drectory.GetFileDateAndTime( NdxFile^.handle, month, day, year,
  2704. ***** ^ not supported yet
  2705. ***** ^ not supported yet
  2706. ***** ^ not supported yet
  2707. ***** ^ not supported yet
  2708. 1069 hours, minutes, seconds );
  2709. ***** ^ not supported yet
  2710. 1070 Date := ByteFiddler.DateToCardinal( month, day, year );
  2711. ***** ^ not supported yet
  2712. ***** ^ not supported yet
  2713. ***** ^ not supported yet
  2714. 1071 IF NOT NdxFiles.GetField( NdxFile, RecName, 'DATE', TypeCode,
  2715. ***** ^ not supported yet
  2716. ***** ^ not supported yet
  2717. ***** ^ not supported yet
  2718. ***** ^ not supported yet
  2719. ***** ^ not supported yet
  2720. 1072 DateStr ) THEN
  2721. ***** ^ not supported yet
  2722. 1073 RETURN;
  2723. 1074 END;
  2724. 1075 IF NOT DateFunctions.StrToDate2( DateStr, FALSE, day, month, year ) THEN
  2725. ***** ^ not supported yet
  2726. ***** ^ not supported yet
  2727. ***** ^ not supported yet
  2728. ***** ^ not supported yet
  2729. 1076 RETURN;
  2730. 1077 END;
  2731. 1078 Date := ByteFiddler.DateToCardinal( month, day, year );
  2732. ***** ^ not supported yet
  2733. ***** ^ not supported yet
  2734. ***** ^ not supported yet
  2735. 1079 END GetRecDate;
  2736. ***** ^ not supported yet
  2737. 1080
  2738. 1081 PROCEDURE FirstIsOlder( VAR date1, date2: CARDINAL ): BOOLEAN;
  2739. 1082 BEGIN
  2740. 1083 RETURN date1 < date2;
  2741. 1084 END FirstIsOlder;
  2742. ***** ^ not supported yet
  2743. 1085
  2744. 1086 PROCEDURE MergeFile();
  2745. 1087 VAR
  2746. 1088 NextFrame: ScrnTypes.AFrameName;
  2747. ***** ^ not supported yet
  2748. 1089 OtherRecName: NdxTypes.RecNameStr;
  2749. ***** ^ not supported yet
  2750. 1090 OtherNdxFile: NdxTypes.NdxFileType;
  2751. ***** ^ not supported yet
  2752. 1091 AddingRecords, AlwaysUpdate, NeverUpdate, Transferring,
  2753. 1092 DoSomething: BOOLEAN;
  2754. 1093 OurDate, TheirDate, cnt: CARDINAL;
  2755. 1094 FileName: ARRAY [0..63] OF CHAR;
  2756. ***** ^ not supported yet
  2757. ***** ^ not supported yet
  2758. 1095 TmpFrame: ScrnTypes.DisplayFrame;
  2759. ***** ^ not supported yet
  2760. 1096
  2761. 1097 BEGIN
  2762. 1098 ScrnTypes.InitDisplayFrame( TmpFrame, VWindows.CurrentWindow );
  2763. ***** ^ not supported yet
  2764. ***** ^ not supported yet
  2765. ***** ^ not supported yet
  2766. ***** ^ not supported yet
  2767. ***** ^ not supported yet
  2768. 1099 LOOP
  2769. 1100 NextFrame := 'MergeOpts';
  2770. ***** ^ not supported yet
  2771. ***** ^ not supported yet
  2772. 1101 ControlUtils.ReadShowAndCntrl( ScreenFile, TmpFrame, NextFrame );
  2773. ***** ^ not supported yet
  2774. ***** ^ not supported yet
  2775. ***** ^ not supported yet
  2776. ***** ^ not supported yet
  2777. ***** ^ not supported yet
  2778. 1102 IF PosUtils.Equal( NextFrame, TmpFrame^.parent ) THEN
  2779. ***** ^ not supported yet
  2780. ***** ^ not supported yet
  2781. ***** ^ not supported yet
  2782. ***** ^ not supported yet
  2783. ***** ^ not supported yet
  2784. 1103 EXIT;
  2785. 1104 END;
  2786. 1105 ControlUtils.ReadInput( TmpFrame, FileName, 'fname' );
  2787. ***** ^ not supported yet
  2788. ***** ^ not supported yet
  2789. ***** ^ not supported yet
  2790. ***** ^ not supported yet
  2791. ***** ^ not supported yet
  2792. 1106 IF NOT NdxBones.OpenNdxFile( OtherNdxFile, FileName ) THEN
  2793. ***** ^ not supported yet
  2794. ***** ^ not supported yet
  2795. ***** ^ not supported yet
  2796. ***** ^ not supported yet
  2797. 1107 EXIT;
  2798. 1108 END;
  2799. 1109
  2800. 1110 AddingRecords := ScrnUtl1.WhichChoiceKey( TmpFrame,
  2801. ***** ^ not supported yet
  2802. ***** ^ not supported yet
  2803. ***** ^ not supported yet
  2804. 1111 ScrnUtl1.FieldNum(TmpFrame, 'add') ) = ORD('y');
  2805. ***** ^ not supported yet
  2806. ***** ^ not supported yet
  2807. ***** ^ not supported yet
  2808. ***** ^ not supported yet
  2809. ***** ^ undeclared identifier
  2810. ***** ^ not supported yet
  2811. 1112 Transferring := ScrnUtl1.WhichChoiceKey( TmpFrame,
  2812. ***** ^ not supported yet
  2813. ***** ^ not supported yet
  2814. ***** ^ not supported yet
  2815. 1113 ScrnUtl1.FieldNum(TmpFrame, 'transf') ) = ORD('y');
  2816. ***** ^ not supported yet
  2817. ***** ^ not supported yet
  2818. ***** ^ not supported yet
  2819. ***** ^ not supported yet
  2820. ***** ^ undeclared identifier
  2821. ***** ^ not supported yet
  2822. 1114 CASE CHR(ScrnUtl1.WhichChoiceKey( TmpFrame,
  2823. ***** ^ undeclared identifier
  2824. ***** ^ not supported yet
  2825. ***** ^ not supported yet
  2826. ***** ^ not supported yet
  2827. 1115 ScrnUtl1.FieldNum(TmpFrame, 'upd') )) OF
  2828. ***** ^ not supported yet
  2829. ***** ^ not supported yet
  2830. ***** ^ not supported yet
  2831. ***** ^ not supported yet
  2832. 1116 'A':
  2833. 1117 AlwaysUpdate := TRUE;
  2834. 1118 NeverUpdate := FALSE;
  2835. 1119 | 'O':
  2836. 1120 AlwaysUpdate := FALSE;
  2837. 1121 NeverUpdate := FALSE;
  2838. 1122 | 'N':
  2839. 1123 AlwaysUpdate := FALSE;
  2840. 1124 NeverUpdate := TRUE;
  2841. 1125 END;
  2842. 1126
  2843. 1127 cnt := 1;
  2844. 1128
  2845. 1129 WHILE NdxUtils.GetRecName( OtherNdxFile, cnt, OtherRecName ) DO
  2846. ***** ^ not supported yet
  2847. ***** ^ not supported yet
  2848. ***** ^ not supported yet
  2849. ***** ^ not supported yet
  2850. 1130 IF NdxFiles.RecordExists( NdxFile, OtherRecName ) THEN
  2851. ***** ^ not supported yet
  2852. ***** ^ not supported yet
  2853. ***** ^ not supported yet
  2854. ***** ^ not supported yet
  2855. 1131 IF AlwaysUpdate THEN
  2856. 1132 DoSomething := TRUE;
  2857. 1133 ELSIF NeverUpdate THEN
  2858. 1134 DoSomething := FALSE;
  2859. 1135 ELSE
  2860. 1136 GetRecDate( NdxFile, OtherRecName, OurDate );
  2861. ***** ^ not supported yet
  2862. ***** ^ not supported yet
  2863. ***** ^ not supported yet
  2864. ***** ^ not supported yet
  2865. 1137 GetRecDate( OtherNdxFile, OtherRecName, TheirDate );
  2866. ***** ^ not supported yet
  2867. ***** ^ not supported yet
  2868. ***** ^ not supported yet
  2869. ***** ^ not supported yet
  2870. 1138 IF FirstIsOlder( OurDate, TheirDate ) THEN
  2871. ***** ^ not supported yet
  2872. ***** ^ not supported yet
  2873. 1139 DoSomething := TRUE;
  2874. 1140 ELSE
  2875. 1141 DoSomething := FALSE;
  2876. 1142 END;
  2877. 1143 END;
  2878. 1144 ELSE
  2879. 1145 DoSomething := AddingRecords;
  2880. 1146 END;
  2881. 1147
  2882. 1148 IF DoSomething THEN
  2883. 1149 IF Transferring THEN
  2884. 1150 IF NOT NdxUtils.TransferRecord(
  2885. ***** ^ not supported yet
  2886. ***** ^ not supported yet
  2887. 1151 OtherRecName, OtherNdxFile, NdxFile ) THEN
  2888. ***** ^ not supported yet
  2889. ***** ^ not supported yet
  2890. ***** ^ not supported yet
  2891. 1152 ErrorManager.WARN( OtherRecName );
  2892. ***** ^ not supported yet
  2893. ***** ^ not supported yet
  2894. ***** ^ not supported yet
  2895. 1153 END;
  2896. 1154 ELSE
  2897. 1155 IF NOT NdxUtils.CopyRecord(
  2898. ***** ^ not supported yet
  2899. ***** ^ not supported yet
  2900. 1156 OtherRecName, OtherNdxFile, NdxFile ) THEN
  2901. ***** ^ not supported yet
  2902. ***** ^ not supported yet
  2903. ***** ^ not supported yet
  2904. 1157 ErrorManager.WARN( OtherRecName );
  2905. ***** ^ not supported yet
  2906. ***** ^ not supported yet
  2907. ***** ^ not supported yet
  2908. 1158 END;
  2909. 1159 END;
  2910. 1160 END;
  2911. 1161
  2912. 1162 INC( cnt );
  2913. ***** ^ undeclared identifier
  2914. ***** ^ not supported yet
  2915. 1163 END;
  2916. 1164 NdxFiles.CloseNdxFile( OtherNdxFile );
  2917. ***** ^ not supported yet
  2918. ***** ^ not supported yet
  2919. ***** ^ not supported yet
  2920. 1165 END;
  2921. 1166 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  2922. ***** ^ not supported yet
  2923. ***** ^ not supported yet
  2924. ***** ^ not supported yet
  2925. 1167 END MergeFile;
  2926. ***** ^ not supported yet
  2927. 1168
  2928. 1169
  2929. 1170 VAR
  2930. 1171 NdxFile2 : NdxTypes.NdxFileType;
  2931. ***** ^ not supported yet
  2932. 1172 TmpFrame: ScrnTypes.DisplayFrame;
  2933. ***** ^ not supported yet
  2934. 1173
  2935. 1174 BEGIN (* FileManagement *)
  2936. 1175 ScrnTypes.InitDisplayFrame( TmpFrame, VWindows.CurrentWindow );
  2937. ***** ^ not supported yet
  2938. ***** ^ not supported yet
  2939. ***** ^ not supported yet
  2940. ***** ^ not supported yet
  2941. ***** ^ not supported yet
  2942. 1176 LOOP
  2943. 1177 NextFrame := '9';
  2944. ***** ^ not supported yet
  2945. 1178 ControlUtils.ReadShowAndCntrl( ScreenFile, TmpFrame, NextFrame );
  2946. ***** ^ not supported yet
  2947. ***** ^ not supported yet
  2948. ***** ^ not supported yet
  2949. ***** ^ not supported yet
  2950. ***** ^ not supported yet
  2951. 1179 IF PosUtils.Equal( NextFrame, TmpFrame^.parent ) THEN
  2952. ***** ^ not supported yet
  2953. ***** ^ not supported yet
  2954. ***** ^ not supported yet
  2955. ***** ^ not supported yet
  2956. ***** ^ not supported yet
  2957. 1180 EXIT;
  2958. 1181 END;
  2959. 1182 CASE ScrnUtl1.SelectedChar(TmpFrame) OF
  2960. ***** ^ not supported yet
  2961. ***** ^ not supported yet
  2962. ***** ^ not supported yet
  2963. 1183 'C': (*Create or select a new file.*)
  2964. 1184 IF GetFile( NdxFile2, ScreenFile, NextFrame) THEN
  2965. ***** ^ not supported yet
  2966. ***** ^ not supported yet
  2967. ***** ^ not supported yet
  2968. ***** ^ not supported yet
  2969. 1185 NdxFiles.CloseNdxFile( NdxFile );
  2970. ***** ^ not supported yet
  2971. ***** ^ not supported yet
  2972. ***** ^ not supported yet
  2973. 1186 NdxFile := NdxFile2;
  2974. ***** ^ not supported yet
  2975. ***** ^ not supported yet
  2976. 1187 END;
  2977. 1188 (*TmpFrame will be 6 at this point; NextFrame will be 9.*)
  2978. 1189 |'s': (*Manage space usage in this file.*)
  2979. 1190 CrunchMenu();
  2980. ***** ^ not supported yet
  2981. ***** ^ not supported yet
  2982. 1191 |'M': (*Merge another file*)
  2983. 1192 MergeFile();
  2984. ***** ^ not supported yet
  2985. ***** ^ not supported yet
  2986. 1193 |'E': (*Edit a file.*)
  2987. 1194 EditFile();
  2988. ***** ^ not supported yet
  2989. ***** ^ not supported yet
  2990. 1195 ELSE
  2991. 1196 END;
  2992. 1197 END;
  2993. 1198 ScrnUtl2.CloseDisplayFrame( TmpFrame );
  2994. ***** ^ not supported yet
  2995. ***** ^ not supported yet
  2996. ***** ^ not supported yet
  2997. 1199 END FileManagement;
  2998. ***** ^ not supported yet
  2999. 1200
  3000. 1201
  3001. 1202 PROCEDURE RestoreDisplay();
  3002. 1203 BEGIN
  3003. 1204 SmartScreen.SetAttribOrColor( SmartScreen.lightgrey,
  3004. ***** ^ not supported yet
  3005. ***** ^ not supported yet
  3006. ***** ^ not supported yet
  3007. ***** ^ not supported yet
  3008. 1205 SmartScreen.black, SmartScreen.plain );
  3009. ***** ^ not supported yet
  3010. ***** ^ not supported yet
  3011. ***** ^ not supported yet
  3012. ***** ^ not supported yet
  3013. 1206 SmartScreen.ClearPart( 1, 1, SmartScreen.MaxCol, SmartScreen.MaxRow );
  3014. ***** ^ not supported yet
  3015. ***** ^ not supported yet
  3016. ***** ^ not supported yet
  3017. ***** ^ not supported yet
  3018. ***** ^ not supported yet
  3019. ***** ^ not supported yet
  3020. 1207 SmartScreen.SetCursorHeight( SavedCursorHeight );
  3021. ***** ^ not supported yet
  3022. ***** ^ not supported yet
  3023. ***** ^ not supported yet
  3024. 1208 END RestoreDisplay;
  3025. ***** ^ not supported yet
  3026. 1209
  3027. 1210
  3028. 1211 PROCEDURE CloseFiles();
  3029. 1212 BEGIN
  3030. 1213 DspFiles.CloseDisplayFile(ScreenFile);
  3031. ***** ^ not supported yet
  3032. ***** ^ not supported yet
  3033. ***** ^ not supported yet
  3034. 1214 NdxFiles.CloseNdxFile( NdxFile );
  3035. ***** ^ not supported yet
  3036. ***** ^ not supported yet
  3037. ***** ^ not supported yet
  3038. 1215 END CloseFiles;
  3039. ***** ^ not supported yet
  3040. 1216
  3041. 1217 VAR
  3042. 1218 NextFrame: ScrnTypes.AFrameName;
  3043. ***** ^ not supported yet
  3044. 1219
  3045. 1220 BEGIN (*Main*)
  3046. 1221 SavedCursorHeight := WindowPrims.GetCursorHeight();
  3047. ***** ^ not supported yet
  3048. ***** ^ not supported yet
  3049. ***** ^ not supported yet
  3050. 1222 SmartScreen.SetCursorHeight( 0 );
  3051. ***** ^ not supported yet
  3052. ***** ^ not supported yet
  3053. ***** ^ not supported yet
  3054. 1223 ErrorManager.AddTermProc( RestoreDisplay );
  3055. ***** ^ not supported yet
  3056. ***** ^ not supported yet
  3057. ***** ^ not supported yet
  3058. 1224 IF NOT DspFiles.OpenDisplayFile( ScreenFile, "pmidbms.dsp") THEN
  3059. ***** ^ not supported yet
  3060. ***** ^ not supported yet
  3061. ***** ^ not supported yet
  3062. ***** ^ not supported yet
  3063. 1225 ErrorManager.WARN( "Could not find PMIDBMS.DSP" );
  3064. ***** ^ not supported yet
  3065. ***** ^ not supported yet
  3066. ***** ^ not supported yet
  3067. 1226 HALT;
  3068. ***** ^ undeclared identifier
  3069. 1227 END;
  3070. 1228 StrEdit.AssignStr( 'pmidbms.ndx', NdxFileName);
  3071. ***** ^ not supported yet
  3072. ***** ^ not supported yet
  3073. ***** ^ not supported yet
  3074. ***** ^ not supported yet
  3075. 1229 GenLists.DiagMode := FALSE;
  3076. ***** ^ not supported yet
  3077. ***** ^ not supported yet
  3078. 1230 IF NOT (NdxBones.OpenNdxFile( NdxFile, NdxFileName) OR
  3079. ***** ^ not supported yet
  3080. ***** ^ not supported yet
  3081. ***** ^ not supported yet
  3082. ***** ^ not supported yet
  3083. 1231 GetFile( NdxFile, ScreenFile, NextFrame)) THEN
  3084. ***** ^ not supported yet
  3085. ***** ^ not supported yet
  3086. ***** ^ not supported yet
  3087. ***** ^ not supported yet
  3088. 1232 ControlUtils.InputConst( DspFiles.MainFrame, '8' );
  3089. ***** ^ not supported yet
  3090. ***** ^ not supported yet
  3091. ***** ^ not supported yet
  3092. ***** ^ not supported yet
  3093. ***** ^ not supported yet
  3094. 1233 (* Tell them we can't proceed without an Ndx file *)
  3095. 1234 DspFiles.CloseDisplayFile( ScreenFile);
  3096. ***** ^ not supported yet
  3097. ***** ^ not supported yet
  3098. ***** ^ not supported yet
  3099. 1235 RETURN;
  3100. ***** ^ bad RETURN
  3101. 1236 END;
  3102. 1237 ScrnTypes.InitDisplayFrame( EntryFrame, VWindows.CurrentWindow );
  3103. ***** ^ not supported yet
  3104. ***** ^ not supported yet
  3105. ***** ^ not supported yet
  3106. ***** ^ not supported yet
  3107. ***** ^ not supported yet
  3108. 1238 ErrorManager.AddTermProc( CloseFiles );
  3109. ***** ^ not supported yet
  3110. ***** ^ not supported yet
  3111. ***** ^ not supported yet
  3112. 1239 LOOP
  3113. 1240 NextFrame := '2';
  3114. ***** ^ not supported yet
  3115. 1241 ControlUtils.Input( DspFiles.MainFrame, NextFrame );
  3116. ***** ^ not supported yet
  3117. ***** ^ not supported yet
  3118. ***** ^ not supported yet
  3119. ***** ^ not supported yet
  3120. ***** ^ not supported yet
  3121. 1242 (*the top menu*)
  3122. 1243 IF PosUtils.Equal( NextFrame, ScrnTypes.ProgramExit ) THEN
  3123. ***** ^ not supported yet
  3124. ***** ^ not supported yet
  3125. ***** ^ not supported yet
  3126. ***** ^ not supported yet
  3127. ***** ^ not supported yet
  3128. 1244 EXIT;
  3129. 1245 END;
  3130. 1246 CASE ScrnUtl1.SelectedChar( DspFiles.MainFrame ) OF
  3131. ***** ^ not supported yet
  3132. ***** ^ not supported yet
  3133. ***** ^ not supported yet
  3134. ***** ^ not supported yet
  3135. 1247 'P': (*Process a record*)
  3136. 1248 ProcessRecord();
  3137. ***** ^ not supported yet
  3138. ***** ^ not supported yet
  3139. 1249 | 'U': (*Search*)
  3140. 1250 ManageLists();
  3141. ***** ^ not supported yet
  3142. ***** ^ not supported yet
  3143. 1251 | 'E': (*Export*)
  3144. 1252 ExportRecords( NdxFile, NextFrame, ScreenFile);
  3145. ***** ^ not supported yet
  3146. ***** ^ not supported yet
  3147. ***** ^ not supported yet
  3148. ***** ^ not supported yet
  3149. 1253 | 'M': (*File Info & Management*)
  3150. 1254 FileManagement( NdxFile, NextFrame, ScreenFile);
  3151. ***** ^ not supported yet
  3152. ***** ^ not supported yet
  3153. ***** ^ not supported yet
  3154. ***** ^ not supported yet
  3155. 1255 ELSE
  3156. 1256 END;
  3157. 1257 END;
  3158. 1258 END PMIdbms.
  3159. 1899 errors