Witam
Napisałem sobie taki o to program:
i czemu po skompilowaniu mi się go otwiera się tylko notepad ?
Napisałem sobie taki o to program:
Kod:
#include <iostream>
#include <windows.h>
#include <winuser.h>
#include <cstdlib>
using namespace std;
HINSTANCE ShellExecute(HWND hwnd, LPCWSTR lpOperation, LPCWSTR lpFile, LPCWSTR lpParametres,LPCWSTR lpDirectory, INT nshowcmd);
char Notepad[MAX_PATH]="notepad.exe";
char Kalkulator[MAX_PATH]="kalkulator.exe";
int main()
{
ShellExecute(NULL, "open", Notepad, NULL, NULL, SW_MAXIMIZE);
ShellExecute(NULL, "open", Kalkulator, NULL, NULL, SW_MAXIMIZE);
system("pause");
return 0;
}