Paradox Community

Items in comp.databases.paradox

Subject:Re: adobe reader from pdox button
Date:Thu, 4 May 2017 17:31:43 +0200
From:"F.Huijsmans" <floris@metroprop.nl>
Newsgroups:comp.databases.paradox
[This followup was posted to comp.databases.paradox and a copy was sent 
to the cited author.]

In article <4d273d31@pnews.thedbcommunity.com>, mattueen@yahoo.com 
says...
> 
> hi -
> 
> in one of the fields of my paradox db i have pdf files stored.
> 
> so, i'd like to open the adobe reader from a button on the form,
> but i can not figure out the correct command to open the adobe reader.
> 
> something like --
> 
> execute("adobe.exe") ??
> 
> we have adobe reader 8.0, 9.0 and 10.0 
> 
> thanks,
> matt

Dear Matt,

This might help: I simply let the explorer decide what to do with a 
file. If the file extension is recognised the proper program is used to 
open the file.

;-----------------------------------------------------------------------
------------------
;simply throw a document to the explorer and let the explorer decide 
what to do with it
method OpenDocument(sDocFile String)
var
	sExeCommand String ;command to execute
endVar

;add " (double quote) to start and end of DocFile name to allow for 
spaces in filename
sExeCommand = "Explorer \"" + sDocFile + "\""
;sExeCommand.view()

;execute(command,wait): wait = True -> wait for explorer to close to 
avoid annoying issues
;when opening for instance multiple instances of Excel using the same 
personal.xls

;Errortraponwarnings(yes)
try
	execute(sExeCommand, True)
onFail
	errorShow()
endTry
;Errortraponwarnings(no)

endMethod



------------ And now a word from our sponsor ------------------
For a quality usenet news server, try DNEWS, easy to install,
fast, efficient and reliable. For home servers or carrier class
installations with millions of users it will allow you to grow!
----  See http://netwinsite.com/sponsor/sponsor_dnews.htm  ----


Copyright © 2004 thedbcommunity.com