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

Bug

When creating a set property custom action the MSI Type Number is wrong



It should be 51

Please fix asap
Labels (1)
0 Kudos
(5) Replies
DebbieL
Level 17

Type 51 is only applicable if the Return Processing setting is set to Synchronous (Check exit code), as shown in the screen shot below. The type number changes for different Return Processing values, and based on the selected values for other settings. (The type number is a decimal value that is calculated by using the OR operator to combine several bits that are available for the Type column in the CustomAction table.)

0 Kudos
KingVoodoo
Level 7

DebbieL wrote:
Type 51 is only applicable if the Return Processing setting is set to Synchronous (Check exit code), as shown in the screen shot below. The type number changes for different Return Processing values, and based on the selected values for other settings. (The type number is a decimal value that is calculated by using the OR operator to combine several bits that are available for the Type column in the CustomAction table.)



Thanks for the reply.
That is exactly my point; when I create the custom action IS will set it to 115 and not 51 as it should be. ERROR.
When i change it manually to 51 it works. The picture is from the faulty setting IS made when I created the custom action.
Also, 115 is not a valid type number which IS put there, not me. When I run the msi I get custom action specifies unsupported type
I found a post about this error from 2009 where it said it should be looked into asap...

///
0 Kudos
stefanm1
Level 4

It is correct
Please check the online help:


Page: CustomAction Table
Type
A field of flag bits specifying the basic type of custom action and options. See Summary List of All Custom Action Types for a list of the basic types. See Custom Action Return Processing Options, Custom Action Execution Scheduling Options, Custom Action Hidden Target Option, and Custom Action In-Script Execution Options.

Page: Custom Action Types
Custom Action Type 51
Property set with formatted text.
51 Property name or key to the Property table. This property is set by the formatted string in the Target field. A formatted text string.

Page: Custom Action Return Processing Options
(none) 0x00000000 +0 A synchronous execution that fails if the exit code is not 0 (zero). If the flag msidbCustomActionTypeContinue is not set, then the custom action must return one of the return values that is described in Custom Action Return Values.
msidbCustomActionTypeContinue 0x00000040 +64 A synchronous execution that ignores exit code and continues.
msidbCustomActionTypeAsync 0x00000080 +128 An asynchronous execution that waits for exit code at the end of the sequence.This option cannot be used with Concurrent Installations, Rollback Custom Actions, or Script Custom Actions.

Synchronous (check exit code) +0 -> 51 + 0 = 51
Synchronous (Ignore exit code) +64 -> 51 + 64 = 115
Asynchronous (waits for exit code) +128 -> 51 + 128 = 179
0 Kudos
KingVoodoo
Level 7

stefanm1 wrote:
It is correct
Please check the online help:


Page: CustomAction Table
Type
A field of flag bits specifying the basic type of custom action and options. See Summary List of All Custom Action Types for a list of the basic types. See Custom Action Return Processing Options, Custom Action Execution Scheduling Options, Custom Action Hidden Target Option, and Custom Action In-Script Execution Options.

Page: Custom Action Types
Custom Action Type 51
Property set with formatted text.
51 Property name or key to the Property table. This property is set by the formatted string in the Target field. A formatted text string.

Page: Custom Action Return Processing Options
(none) 0x00000000 +0 A synchronous execution that fails if the exit code is not 0 (zero). If the flag msidbCustomActionTypeContinue is not set, then the custom action must return one of the return values that is described in Custom Action Return Values.
msidbCustomActionTypeContinue 0x00000040 +64 A synchronous execution that ignores exit code and continues.
msidbCustomActionTypeAsync 0x00000080 +128 An asynchronous execution that waits for exit code at the end of the sequence.This option cannot be used with Concurrent Installations, Rollback Custom Actions, or Script Custom Actions.

Synchronous (check exit code) +0 -> 51 + 0 = 51
Synchronous (Ignore exit code) +64 -> 51 + 64 = 115
Asynchronous (waits for exit code) +128 -> 51 + 128 = 179


Hi,
no it is not correct. The type number for a set property custom action is 51.

Excerpt from microsoft:

"Custom Action Type 51


This custom action sets a property from a formatted text string.
To affect a property used in a condition on a component or feature, the custom action must come before the CostFinalize action in the action sequence.
Source
The Source field of the CustomAction table can contain either the name of a property or a key to the Property table. This property is set by the formatted string in the Target field using MsiSetProperty.
Type Value
Include the following value in the Type column of the CustomAction table to specify the basic numeric type.
Constants
msidbCustomActionTypeTextData + msidbCustomActionTypeProperty Hexadecimal: 0x033, Decimal: 51"


As you can see it says Custom Action Type 51 NOT Custom Action Type 115.

Try this in Wise and you'll see what it should look like.

Also, the error message custom action specifies unsupported type is a clear indication that it is not correct.
0 Kudos
KingVoodoo
Level 7

Tried this in a new project and it works in that. Guess my old project is corrupt. 😞
0 Kudos