Running lnk files from C++ program

vsaravana used Ask the Experts™
Hello All,
I am trying to run a lnk file from a C++ program(using MFC). I have tried using Winexec and Createprocess and none of them work. However the API "system ()" works but it brings a DOS window. I don't want to use the Ishelllink interface as I have other issues with it. In short I just need to run the lnk file directly from my C++ program without any DOS window.


Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Sorry, you'll HAVE to use either IShellLink or ShellExecute().  The problem is that lnk files are a manifestation of the Windows shell NOT the Windows kernel.  As such, they are meaningless apart from the shell's interpretation of them.


ShellExecute was the API I was looking for. Thanks

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial