home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Datafile PD-CD 3
/
PDCD_3.iso
/
pocketbk
/
utilsa
/
export
/
EXPORT.OPL
next >
Wrap
Text File
|
1992-10-03
|
831b
|
48 lines
PROC Export:
local d%,c%,xfil$(128),p%,l%
p%=pos
top::
dinit"Export Notepad as Text"
dbuttons "Yes",%Y,"Cancel",27
d%=dialog
if d%=%y or d%=%Y
xfil$="\"
fn::
giprint"Path is "+parse$:(f$,1)+parse$:(f$,2)+"\"
dinit"Choose Filename"
dfile xfil$,"File:",19
l%=2
dchoice l%,"Line numbers:","Yes,No"
if dialog=0
goto top
endif
first
trap lopen xfil$
if err
giprint err$(err)
goto fn
endif
busy"Exporting..."
lprint"Notepad Export File: "+date$
lprint"---------------------------"
lprint"File: "+parse$:(f$,6)
lprint
do
if l%=1
lprint fix$(pos,0,4)+") "+mid$(d.n$,13,240)
else
lprint mid$(d.n$,13,240)
endif
next
until eof
busy off
giprint"Done"
beep 5,50
pause 30
giprint parse$:(xfil$,4)+" saved..."
pause 30
trap lclose
position p%
endif
ENDP