This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- CustomActionData not passing
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Oct 30, 2009
11:55 AM
CustomActionData not passing
Ok, this is driving me crazy.
I have a CA that needs to know the path of the INSTALLDIR to edit an XML file.
So, I set up a set property custom action that sets a property named RemoveAuthTypesNode to [INSTALLDIR]. Then I have a RemoveAuthTypesNode CA that is sequenced after SetConfigFolder (a set property that sets installdir to a system searched path) in the Install Execute Sequence, Deferred in System Context (doesn't work when just Deferred Exec either).
In the log I see that RemoveAuthTypesNode is set:
MSI (c) (D4:EC) [16:12:05:314]: PROPERTY CHANGE: Adding RemoveAuthTypesNode property. Its value is 'C:\Program Files\Microsoft SQL Server\MSRS10.MSSQLSERVER\Reporting Services\ReportServer\'.
The custom action errors:
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 RemoveAuthTypesNode script error -2146827864, Microsoft VBScript runtime error: Object required: 'objXMLDOMNode' Line 9, Column 1,
MSI (s) (78:EC) [16:12:23:916]: Product: ASMI User Defined Reports -- 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 RemoveAuthTypesNode script error -2146827864, Microsoft VBScript runtime error: Object required: 'objXMLDOMNode' Line 9, Column 1,
This is failing because the path isn't correct so the XMLDom object never loads. I know this because if I hardcode the path everything works fine.
Also, when I search the log for CustomActionData I expected that it would be in there as being set.
Here is the code from the custom action. The msgbox is just for debugging. It is always displaying nothing.
strConfigFile = session.Property("CustomActionData") & "rsreportserver.config"
MsgBox session.Property("CustomActionData")
Set xDoc = CreateObject("Microsoft.XMLDOM")
xDoc.async = False
xDoc.Load(strConfigFile)
set objXMLDOMNode = xDoc.selectSingleNode("//Configuration/Authentication/AuthenticationTypes")
set objParentNode = objXMLDOMNode.parentNode
objParentNode.removeChild(objXMLDOMNode)
xDoc.save(strConfigFile)
Set xDoc = Nothing
What am I doing wrong. I'm sure it's something simple stupid. Help greatly appreciated.
Thanks,
BOb
Edit/Delete Message
I have a CA that needs to know the path of the INSTALLDIR to edit an XML file.
So, I set up a set property custom action that sets a property named RemoveAuthTypesNode to [INSTALLDIR]. Then I have a RemoveAuthTypesNode CA that is sequenced after SetConfigFolder (a set property that sets installdir to a system searched path) in the Install Execute Sequence, Deferred in System Context (doesn't work when just Deferred Exec either).
In the log I see that RemoveAuthTypesNode is set:
MSI (c) (D4:EC) [16:12:05:314]: PROPERTY CHANGE: Adding RemoveAuthTypesNode property. Its value is 'C:\Program Files\Microsoft SQL Server\MSRS10.MSSQLSERVER\Reporting Services\ReportServer\'.
The custom action errors:
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 RemoveAuthTypesNode script error -2146827864, Microsoft VBScript runtime error: Object required: 'objXMLDOMNode' Line 9, Column 1,
MSI (s) (78:EC) [16:12:23:916]: Product: ASMI User Defined Reports -- 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 RemoveAuthTypesNode script error -2146827864, Microsoft VBScript runtime error: Object required: 'objXMLDOMNode' Line 9, Column 1,
This is failing because the path isn't correct so the XMLDom object never loads. I know this because if I hardcode the path everything works fine.
Also, when I search the log for CustomActionData I expected that it would be in there as being set.
Here is the code from the custom action. The msgbox is just for debugging. It is always displaying nothing.
strConfigFile = session.Property("CustomActionData") & "rsreportserver.config"
MsgBox session.Property("CustomActionData")
Set xDoc = CreateObject("Microsoft.XMLDOM")
xDoc.async = False
xDoc.Load(strConfigFile)
set objXMLDOMNode = xDoc.selectSingleNode("//Configuration/Authentication/AuthenticationTypes")
set objParentNode = objXMLDOMNode.parentNode
objParentNode.removeChild(objXMLDOMNode)
xDoc.save(strConfigFile)
Set xDoc = Nothing
What am I doing wrong. I'm sure it's something simple stupid. Help greatly appreciated.
Thanks,
BOb
Edit/Delete Message
(1) Reply
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Oct 30, 2009
12:39 PM
I finally found the answer after much googling.
You have to sequence the set property CA which sets the property named for the vbscript custom action in the Execute sequence. I assume this is because it is a private (not all uppercase) property and private properties don't pass from the UI sequence to the Execute sequence.
BOb
You have to sequence the set property CA which sets the property named for the vbscript custom action in the Execute sequence. I assume this is because it is a private (not all uppercase) property and private properties don't pass from the UI sequence to the Execute sequence.
BOb
![](/skins/images/A5EADE085F77DE82FB3B14D6B307AE6A/responsive_peak/images/icon_anonymous_message.png)