Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Determing Program
Message
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00221777
Message ID:
00221890
Views:
10
>Is there any way,using VFP to find out if the Internet Explorer is starting or Netscape, or i should use other languaegs.
>
>Please help

Hi Galia,

Two ways come to mind. The first, requires the name of an html file (with the htm extension). This can be a real file or you can create a dummy one on the fly. However, the file must exsist.
* lcfile is the HTM file
DECLARE INTEGER FindExecutable IN Shell32;
  STRING @lpfile, STRING @lppath, STRING @lpbuffer
* Requires foxtools in 5.0
lcpath = JUSTPATH(lcfile)
lcbuffer = SPACE(260)
lnresult = FindExecutable(@lcfile, @lcpath, @lcbuffer)
If the function succeeds the return value will be greater than 32. If I recall correctly, 31 means that no association exists.

The other method requires querying the registry. The Solutions sample that shipped with VFP 5.0 (and maybe with 6.0), demonstrates how to retrieve the associated application based solely on the extension.

hth,
George

Ubi caritas et amor, deus ibi est
Previous
Reply
Map
View

Click here to load this message in the networking platform