>I'm creating an application manager for the office. The idea is that the foxpro application will read a table and then create and display an HTML page. The HTML page will have links relating to applications the user has access to, and can run them by clicking on the links (the manager will also run updates automatically, and other maintenance things in the background).
>
>The problem is that if you simply point the link to an application file using an "a href" tag, when you click on the link a window pops up to inform you that you are trying to download a file to your hard drive (from your hard drive, no less) and would you like to open, save, cancel, or get more information. Is there any way, using HTML and/or FoxPro, to click on a link and run an application without getting this message?
>
>Robert
Not directly. Garrett's suggestion is the only way to handle this. Basically, you put code in the BeforeNavigate2() event of the IE control. Then you parse out the original string, and call the app from within your VFP code:
FUNCTION BeforeNavigate2()
LPARAMETERS pdisp, url, flags, targetframename, postdata, headers, cancel
LOCAL lnAT, ;
lcText
lnAt = atc("HTTP://", upper(url))
lcText = upper(alltrim(substr(url, lnAt + 6)))
DO CASE
CASE lcText = "Some HTTP call goes here"
RUN SomeApp.EXE
OTHERWISE
ENDCASE
cancel = .T.
ENDFUNC