cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
palanisamy
Level 7

Custom Action Error 2147467259

I am facing the following error during custom action launch

"Error 1720.There is a problem with this Windows Installer package. A script required for this install to complete could not be run. Contact your support personnel or package vendor. Custom action SetFeaturestate script error -2147467259, Msi API Error: FeatureRequestState,feature Line 11, Column 9, "

My Custom action :
Custom action : Type - 38
Script Execution : Immediate Execution
Script :
Dim svAppUserProp, svPriviProp, svAdminProp
svAppUserProp = Trim(Session.property("APPLICATIONUSERS"))
svPriviProp = Trim(Session.property("Privileged"))
svAdminProp = Trim(Session.property("AdminUser"))
if ((svPriviProp <> "1") OR (svAdminProp <> "1") OR ((svAppUserProp = "OnlyCurrentUser") AND (svPriviProp = "1"))) then
Session.FeatureRequestState("Feature1") = 3
Session.FeatureRequestState("Feature2") = 2
Session.Property("INSTALLDIR") = Trim(Session.Property("USERPROFILE")) + "MYCompany\MyProduct"
end if
if ((svAppUserProp = "AllUsers") AND (svPriviProp = "1")) then
Session.FeatureRequestState("Feature2") = 3
Session.FeatureRequestState("Feature1") = 2
Session.Property("INSTALLDIR") = Trim(Session.Property("ProgramFilesFolder")) + "MYCompany\MyProduct"
end if



I called this custom action on "customer Information" dialog "Next" button "Doaction" Event

Please help.
Labels (1)
0 Kudos
(3) Replies
MSIYER
Level 8

Run the script from command line:
cscript and see the result...
0 Kudos
palanisamy
Level 7

Thanks for reply MSIYER

In UI Sequence i solved the issue using cscript.exe file

I am facing the issue on Silent installtion using /qb parameter, I call the custom action After CostInitialize

Features are not selected during the installation, please saw some content in LOG file below
MSI (s) (EC:30) [20:22:50:093]: Feature: Feature1; Installed: Absent; Request: Local; Action: Local
MSI (s) (EC:30) [20:22:50:093]: Feature: Feature2; Installed: Absent; Request: Local; Action: Local
l
0 Kudos
TsungH
Level 12

With /qb command line switch, UI Sequence is skipped. The same custom action will need to be scheduled in Execute Sequence as well to resolve the expected behavior encountered.

For comparisons like what you are doing, custom action is an overkill and is not recommended. You can make use of Level column in Features (Feature table) instead.
0 Kudos