ErrorMessage custom action doesn't show my custom property - Advanced Installer Community
cirio89
Posts: 2
Joined: Mon Apr 01, 2019 3:32 pm

ErrorMessage custom action doesn't show my custom property

I've a custom action with a powershell script. Inside the script i've set a custom property :

Code: Select all

AI_SetMsiProperty ERROR_ALREADYUPGRADE "Test"

In my "Display error message" popup I need to catch the variabile e show the error... but it's always empty,
The ERROR_ALREADYUPGRADE is not readed.

thanks.
Attachments
err.PNG
err.PNG (17.44 KiB) Viewed 2954 times
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: ErrorMessage custom action doesn't show my custom property

Hi and welcome to Advanced Installer forums.

I'm not sure why you encounter this problem. Can you please send me the .AIP (project file) and a verbose log of the installation to support at advancedinstaller dot com, so I can investigate them?

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
cirio89
Posts: 2
Joined: Mon Apr 01, 2019 3:32 pm

Re: ErrorMessage custom action doesn't show my custom property

Hi,
I found a solution: my ERROR_ALREADYUPGRADE property depending by a user interface property and when my custom action is set on Execution Time Immediately the parameter it's not available.
When the custom action is set on "After the system ecc" is OK.

Now, i've another issue: the template action "Display error message" it's available only in "Immediately" scope
viewtopic.php?t=34495
And so i write a custom powershell script message box:

Code: Select all

[System.Reflection.Assembly]::LoadWithPartialName('System.Windows.Forms')
...
...
[System.Windows.Forms.MessageBox]::Show($MessageBody,$MessageTitle,$ButtonType,$MessageIcon)
The message it's shown, however the popup it's behind of setup (attached). Can i fix it the position?
Attachments
err.PNG
err.PNG (15.69 KiB) Viewed 2928 times
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: ErrorMessage custom action doesn't show my custom property

Hi,

I'm afraid that I'm not aware of any solution of bringing that message box to the front. Also, I do not understand why your property is only available during the "commit" phase if it is actually set on the dialogs stage.

Can you please send me the .AIP (project file) and a verbose log of the installation to support at advancedinstaller dot com, so I can investigate them?

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”