Reputation: 63
So I have the following code and anytime it is called it appears behind everything else. Does anybody have any idea of how I can make sure this prompt shows up at the front every time?
sPromptA = "Question that is asked to user";
MODE = NORMALMODE;
if (NO = AskYesNo(sPromptA, NO)) then
MODE = SILENTMODE;
Upvotes: 1
Views: 1043
Reputation: 3230
You can work around this:
HWND hRecord;
sMsg = "my message";
hRecord = MsiCreateRecord(1);
MsiRecordSetString( hRecord, 0, sMsg);
nYesNoResult = MsiProcessMessage(hMSI, INSTALLMESSAGE_USER + MB_YESNO, hRecord);
MsiCloseHandle(hRecord);
if (nYesNoResult = 6) then //6=yes 7=no
//do something
endif;
Upvotes: 2