I am trying to set security permissions on an object. This is the code:
PROCESS_INFORMATION pi = {0};
STARTUPINFO si = {0};
si.cb = sizeof(STARTUPINFO);
CreateProcess("C:\\AP\\DataBase\\dbntsrv.exe", NULL, NULL, NULL, FALSE, CREATE_NO_WINDOW, NULL, "C:\\ADP\\SQLBase", &si, &pi);
result = SetSecurityInfo(pi.hProcess, SE_WINDOW_OBJECT, PROCESS_TERMINATE, NULL, NULL, NULL, NULL);
But it gives me compile time error of 'SetSecurityInfo' : undeclared identifier.. and 'SE_WINDOW_OBJECT' : undeclared identifier.. Any idea why this happens? Thanks
In the Windows documentation, it says you need to include
Aclapi.h. Have you?