
?-Save selected Record as text file.
Hi Deb,
Quote:
> Is there, by chance, a sample app out there that shows how to save a selected
> record as a text file (txt or rtf). (You know...on the help bar, File > Save >
> Save As). I've gotten a couple of responses to this question, but somehow its
> just not clicking.
Can't send an attachment from my newsreader, but try to explain.
In Dictionary:
MyFile FILE,DRIVER('SomeDriver'),PRE(FIL)
RECORD RECORD
... !Your fields here
END
TxtFile FILE,DRIVER('ASCII'),PRE(TXT)
RECORD RECORD
... !Your fields here
END
In App Gen.
Define Browse with menu or button "Save As".
In accepted embed of menu or button:
In Legacy (BRWx is the prefix of your browsing queue, see generated source,
if you have 1 list it probably be BRW1):
BRWx::CurrentChoice = CHOICE(?List)
GET(Queue:Browse,BRWx::CurrentChoice)
...
REGET(BRWx::View:Browse,BRWx::Position)
In ABC there is a method BRWx.UpdateBuffer()
Then assign values to fields
CLEAR(TXT:RECORD)
TXT:F1 = FIL:F1
...
ADD(TextFile)
If there'll be more questions e-mail me and i'll try to send you a demo
app. E-mail see below.
Regards,
Anton Novikov