>Hello all,
>
>I have a FPW26 app that uses the RegFn of Foxtools to access the RegQueryValue function of the Windows API. I use this to locate the directory of Word for Windows. When run on an NT workstation however it can't find the RegQueryValue. I guess it is because either FPW can't get to the 32bitAPI of NT, or the API function has a different name.
>
>Any suggestions? How else might I automatically locate an executables full path that would work under NT and Win311/95?
>
>Thanks in advance
>
Hi Peter,
You might want to try FindExecutable in the Shell.dll. Try this code:
* lcdoc is a document file name
lcpath = JustPath(lcdoc)
lcbuffer = SPACE(200)
m.findexe = RegFN("FindExecutable", "@C@C@C", "I", "SHELL.DLL")
m.result = CallFN(m.findexe, @lcdoc, @lcpath, @lcbuffer)
The lcbuffer should contain the name and path of the executable.
hth,
George
Ubi caritas et amor, deus ibi est