PDA

View Full Version : MsiProcessMessage Question



aviswanathan
07-18-2005, 02:55 PM
Hi guys,

This is the quote from MSDN on MsiProcessMessage.


To send an error message from a custom action that uses a dynamic-link library (DLL), have the custom action call MsiProcessMessage. Note that custom actions launched by a DoAction ControlEvent can send messages with the Message method but cannot send a message with MsiProcessMessage. On systems earlier than the Windows Server 2003 family, custom actions launched by a DoAction ControlEvent cannot send messages with MsiProcessMessage or Message method. For more information, see Sending Messages to Windows Installer Using MsiProcessMessage
My question:
Project type: Basic MSI
I tried calling a dll function (a type 1 CA) that had MsiProcessMessage code and sequenced it immediately after AppSearch. It worked perfectly and popped up a message box.

When I called the same function (through a different Type 1 CA) after hooking it to a DoAction event of a "Next" button, the message gets logged into a file, but the message box does not show up.

I tried running the scenarios mentioned above on a Windows 2003 box and ended up with the same result as above.

Has some one found a solution to this problem? Or is it something we have to live with?

nitsev
10-04-2005, 02:18 AM
I have the same behaviour. Calling the function in sequence works fine, but using DoAction does not work at all. I have tried on XP and Server 2003 with MSI 3.0 and 3.1 but it simply does not work. Total **** if you ask me. I will try calling MSIProcessMessage with INSTALLMESSAGE_INFO to log it to the log and then display my own error message using MessageBox.


Hi guys,

This is the quote from MSDN on MsiProcessMessage.


My question:
Project type: Basic MSI
I tried calling a dll function (a type 1 CA) that had MsiProcessMessage code and sequenced it immediately after AppSearch. It worked perfectly and popped up a message box.

When I called the same function (through a different Type 1 CA) after hooking it to a DoAction event of a "Next" button, the message gets logged into a file, but the message box does not show up.

I tried running the scenarios mentioned above on a Windows 2003 box and ended up with the same result as above.

Has some one found a solution to this problem? Or is it something we have to live with?