// // TAB2FIX-3.VDM Christian Ziemski 20.08.2004 // // // Converts TAB separated data into fixed length data // // This version of the macro tries to workaround VEDITs current number-of-TABs limit. // All TAB-stops are set equally to the length of the largest entry. // That may blow up the resulting data file but it works. // BoF Search("|T", BEGIN+NOERR) // any TAB separators found? if (EM) { return // no? then nothing to do } BoF #103=0 // max length of entries while (! At_EoF) { // loop through all data lines #104=1 // current character position in line repeat (ALL) { // loop through current line Search_Block("|T", Cur_Pos, EoL_Pos, NOERR+ERRBREAK) #105 = Cur_Pos-BoL_Pos-#104+1 // length of current field #103 = Max(#103, #105) // find max. length field Char(1) #104=Cur_Pos-BoL_Pos+1 // current character position in line } Line(1, NOERR) } Config_Tab(#103+1) // uniform TAB stepping Detab_Block(0, File_Size) // TABs to spaces BoF