$ ! schd97_offc.com ver0.0 10/8/97 ads $ ! Select, order, group, and format class schedule data for export $ ! as ASCII, var len, "|" delim, for final formatting of Class Schedule $ ! from: $ ! schd_offc.com ver2.0 3/24/94 ADS $ ! Select, order, group, and format class schedule data for import $ ! into WordPerfect for final formatting of Class Schedule. $ ! Group classes by location by day/eve, sort by number by section $ ! $ say = "write sys$output" $ asq = "$dms:asq" $ say - "Prepare PrePrint Schedule File for EACC OFF-CAMPUS (OFFCAMPUS[#64]="Y"):" $ say "" $ inquire tcode "Enter TermCode (e.g., 934)" $ tcode = f$edit(tcode,"collapse") ! remove spaces $ tcode = f$extract(0,3,tcode) ! use 1st 3 characters only $ coso = "[debra.coursefiles]"+tcode+"scourse" $ say "Source file is: " + coso $ say "" $ define/nolog course_source 'coso' $ if f$search("offc*.*.*") .NES. "" then delete offc*.*.* $ say "Extracting Schedule Data via ASQ:" $ say "" $ asq set source course_source,[reg.files]catalog via .COURSE display #5,#9,.FULLTITLE via .COURSE,#41,#42,#40,#39,#32,#71,#38 - where #64="Y" - into offc1.lst display #5,#9,.FULLTITLE via .COURSE,#45,#46,#44,#43,#32,#71,#38 - where #64="Y" and #44 <> "" - into offc2.lst $ say "" $ lst2=f$search("offc2.lst;*") $ if lst2 .EQS. "" $ then $ copy offc1.lst offc12.lst $ else $ copy offc1.lst,offc2.lst offc12.lst $ endif $ say "Sorting by LOCATION, DAY/EVENING, COURSE-SECTION and" $ say " moving associated labs under corresponding lecture." $ sortit/key=(pos:73,siz:6)/key=(pos:1,siz:7) - /key=(pos:10,siz:2)/key=(pos:8,siz:1,desc) - /stable offc12.lst offc12.srt $ say "" $ say "Preparing class records for ASCII export" $ run fieldsoffc97 OFFC12 $ xferfile = tcode+"OFFC.ASC" $ rename offc12.fwp 'xferfile' $ say "File to transfer is: " + xferfile