Alright so i need to open a .txt file that will be created in the same file as the program.
I would like to use ShellExecute(); to do this and i have done a lot of
The ShellExecute function syntax on MSDN:
HINSTANCE ShellExecute( _In_opt_ HWND hwnd, _In_opt_ LPCTSTR lpOperation, _In_ LPCTSTR lpFile, _In_opt_ LPCTSTR lpParameters, _In_opt_ LPCTSTR lpDirectory, _In_ INT nShowCmd );
You can try like this.
You could open "notepad"
with parameter of your text file path ("c:\\debug.txt"
):
ShellExecute(0,"open", "notepad", "c:\\debug.txt", NULL, SW_SHOW);