共用方式為


Script Complex Type

Specifies the script to run.

<xs:complexType name="Script">
    <xs:sequence>
        <xs:element name="Parameters"
            type="dcmPS:Parameters"
            minOccurs="0"
            maxOccurs="1"
        >
            <xs:unique name="No_script_parameters_may_have_the_same_name">
                <xs:selector
                    xpath="Parameter"
                 />
                <xs:field
                    xpath="Name"
                 />
            </xs:unique>
        </xs:element>
        <xs:element name="ProcessArchitecture"
            type="dcmPS:ProcessArchitecture"
            minOccurs="0"
            maxOccurs="1"
         />
        <xs:element name="RequiresElevation"
            type="xs:boolean"
            minOccurs="0"
            maxOccurs="1"
         />
        <xs:element name="RequiresInteractivity"
            type="xs:boolean"
            minOccurs="0"
            maxOccurs="1"
         />
        <xs:element name="FileName"
            type="dcmPS:Name"
            minOccurs="0"
            maxOccurs="1"
         />
        <xs:element name="ExtensionPoint"
            type="dcmPS:ExtensionPoint"
            minOccurs="0"
            maxOccurs="1"
         />
    </xs:sequence>
</xs:complexType>

Child elements

Element Type Description
ExtensionPoint dcmPS:ExtensionPoint Used by the client to extend the functionality of the Script node. The MSDT client does not support extensions for the Script node.
FileName dcmPS:Name The name of the script to run.
Parameters dcmPS:Parameters Arguments to pass to the script.
ProcessArchitecture dcmPS:ProcessArchitecture The architecture on which the script can run. Should be set to ANY unless you have specific dependencies on 32-bit or 64-bit tools.
RequiresElevation xs:boolean Specify true if the script requires elevated privileges to run; otherwise, false.
RequiresInteractivity xs:boolean Specify true if the script uses interactions; otherwise, false. If false, you cannot use the Get-DiagInput cmdlet.

Remarks

You must specify all children; specifying a subset of the children generates an error.

Requirements

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

See also

Script (Resolver) Element

Script (Troubleshooter) Element

Script (Verifier) Element