- Posted by Ray Smith <Ray.Smith at FUJITSU.COM.AU> May 14, 1999
- 1781 views
ee is defined as an atom (the file size) and the message_box expects it to be a sequence, instead of ee, try sprintf("%d", ee), ie. converting it to a sequence. ie. the line should be: r = message_box(sprintf("%d", ee),"File Size",0) If your confused try reading library.doc for "dir" and "message_box", hope that helps, From the chilly city of Orange NSW, to the chilly city of Canberra Ray Smith >I cant seem to get the following to work.... > >global object ee >global sequence fName >global fName = "dir.tmp" >global sequence d > >procedure GetDirs() > system("dir *.exw /b /s > dir.tmp",0) > fName = "dir.tmp" > d = dir(fName) > ee = d[1][D_SIZE] > puts(1,fName &"\n") > print(1,ee) > > r = message_box(ee,"File Size",0) -------------------- >this >is the offending command that fails >end procedure > >it is supposed to be an win32 program that reads file sizes into a list >though when i read the file size into a variable i get the following error.... > >C:\EUPHORIA\INCLUDE\msgbox.e:68 in function message_box() >type_check failure, text is 1381 >... called from C:\EUPHORIA\Programs\ac.exw:24 in procedure GetDirs() >... called from C:\EUPHORIA\Programs\ac.exw:39 >--> see ex.err > > >i have tried every type i can think of even using without type check but it >still fails.... >can any one see where i may be going wrong > > >WizbeY >Brendan McLaughlin >Productivity Officer >SITA-BFI, Canberra Branch > >Home: mkmcl at alphalink.com.au http://www.alphalink.com.au/~mkmcl/ >Work: bmc0373 at sita-bfi.com.au http://www.sita-bfi.com.au >Phone: 02 6260 1464 >Fax: 02 6260 1777 >