Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
A question about acrobat reader
Message
From
28/10/2001 05:24:36
 
 
General information
Forum:
Visual FoxPro
Category:
Third party products
Miscellaneous
Thread ID:
00574202
Message ID:
00574216
Views:
33
Hi Carlos


Cetin Basoz showed me this solution from the solution.app in VFP. It retrieves the application associated with a file extention and also the version number of the application. Here it is to find application associated with .DOC files:


LOCAL cExtn,cAppKey,cAppName
LOCAL oReg,regfile
cAppKey = ""
cAppName = ""
oReg = NewObject("FileReg",HOME()+"FFC\registry.vcx")

* Get Application
nErrNum = oReg.GetAppPath('DOC',@cAppKey,@cAppName)

* Remove switches here (i.e., C:\EXCEL\EXCEL.EXE /e)
IF ATC(".EXE",m.cAppName) #0
m.cAppName= ALLTRIM(SUBSTR(m.cAppName,1,ATC(".EXE",m.cAppName)+3))
IF ASC(LEFT(cAppName,1))=34 &&check for long file name in quotes
m.cAppName = SUBSTR(m.cAppName,2)
ENDIF
ENDIF
? 'App:',LOWER(m.cAppName)
? 'Version:', RIGHT(m.cAppKey,1)
In the End, we will remember not the words of our enemies, but the silence of our friends - Martin Luther King, Jr.
Previous
Reply
Map
View

Click here to load this message in the networking platform