0

Ok so heres what I am trying to do to help you understand my question. I am making my WINAPI load hidden so it's not in the taskbar and is only running as a process using ShowWindow(hwnd, SW_HIDE) on case WM_CREATE:

Now what I am trying to do is make my api run a file on my c:\ .
For example I got a program that I use that is a mouse macro recorder. It records mouse clicks and movements etc.. and it saves the recorded file as c:\ace.scp . So if I clicked on c:\ace.scp the recording runs the recorded clicks and so forth, and if I run c:\ace.scp through command line console it runs etc.. but what I am trying to do is make my api run it. So in my api as with my console experience what I did was placed system("c:\ace.scp"); right under my WM_CREATE case, and it runs the ace.scp, but it keeps a console window open. I dont want the console window open at all. Is there a way to run the ace.scp, or any executable without using system("DPATH"); ??? Like an windows API version that doesnt execute the program through an obvious console?

I'm really hoping to get a simple function that can do this and not a huge block of code, but either way whatever works.

1
Contributor
1
Reply
2
Views
7 Years
Discussion Span
Last Post by CodyOebel
0

Ok so heres what I am trying to do to help you understand my question. I am making my WINAPI load hidden so it's not in the taskbar and is only running as a process using ShowWindow(hwnd, SW_HIDE) on case WM_CREATE:

Now what I am trying to do is make my api run a file on my c:\ .
For example I got a program that I use that is a mouse macro recorder. It records mouse clicks and movements etc.. and it saves the recorded file as c:\ace.scp . So if I clicked on c:\ace.scp the recording runs the recorded clicks and so forth, and if I run c:\ace.scp through command line console it runs etc.. but what I am trying to do is make my api run it. So in my api as with my console experience what I did was placed system("c:\ace.scp"); right under my WM_CREATE case, and it runs the ace.scp, but it keeps a console window open. I dont want the console window open at all. Is there a way to run the ace.scp, or any executable without using system("DPATH"); ??? Like an windows API version that doesnt execute the program through an obvious console?

I'm really hoping to get a simple function that can do this and not a huge block of code, but either way whatever works.

ShellExecute(NULL, "open", "c:/program files/AutoMacroRecorder/ace.scp", NULL, NULL, SW_HIDE);


WOOT FOUND IT.. unless someone has something better

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.