共用方式為


Choice Complex Type

Defines a choice for a single selection or multiple selection list.

<xs:complexType name="Choice">
    <xs:sequence>
        <xs:element name="DisplayInformation"
            type="dcmPS:DisplayInformation"
            minOccurs="1"
            maxOccurs="1"
         />
        <xs:element name="Value"
            type="xs:string"
            minOccurs="1"
            maxOccurs="1"
         />
        <xs:element name="ExtensionPoint"
            type="dcmPS:ExtensionPoint"
            minOccurs="1"
            maxOccurs="1"
         />
    </xs:sequence>
</xs:complexType>

Child elements

Element Type Description
DisplayInformation [dcmPS:DisplayInformation](package-displayinformation-complextype.md) The name and description of the choice.
ExtensionPoint [dcmPS:ExtensionPoint](package-extensionpoint-complextype.md) An extension point that extends the single-response or multiple-response choice. Each extension is a child element of ExtensionPoint. The extension points are MSDT specific and are not supported by the command-line client using the [Invoke-TroubleshootingPack](invoke-troubleshootingpack-cmdlet.md) cmdlet. You can specify one or more of the following extensions.
Extension Description
Default Specifies the default selection for a single-response interaction or default selections for a multiple-response interaction. If you specify a default choice for more than one choice in a single-response interaction, the behavior is undefined. The default has no effect if you also specify the CommandLinks extension point.
The Default element has no content.
Icon An icon to display next to the choice. If you specify the CommandLinks extension point, the icon replaces the green arrow icon.
The Icon element contains the resource identifier for the icon (for example, "@resource.dll,-123").
RTFDescription A rich text format string that replaces the Description element of [DisplayInformation](package-displayinformation-complextype.md). If the client does not support rich text, the description string is used.
The RTF string can contain substitution strings (for example, %param%) that are specified in the ContextParameters element of the single-response or multiple-response interaction.
The RTFDescription element can contain an RTF string or a localized resource string (for example, "@diag.dll,-123" or "@diag.dll,RESOURCE.RTF").

Value xs:string

The value to return if the choice is selected from the list.

Requirements

Minimum supported client
Windows 7 [desktop apps only]
Minimum supported server
Windows Server 2008 R2 [desktop apps only]

See also

Choice (Choices) Element