serverpreview:ServiceParameterKey

Specifies a parameter for the service. This parameter corresponds to a registry subkey that is created under the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ServiceName\Parameters key.

Element hierarchy

<Package>
<Applications>
<Application>
<Extensions>
<serverpreview:Extension>
<serverpreview:NTServices>
<serverpreview:NTService>
<serverpreview:ServiceParameters>
<serverpreview:ServiceParameterKey>


Syntax

<serverpreview:ServiceParameterKey Subkey = A string between 1 and 255  
                                            characters in length that cannot  
                                            start or endwith a period or  
                                            contain these characters: <, >,  
                                            :, ", /, \, |, ?, or *. >
</serverpreview:ServiceParameterKey>

Attributes and Elements

Attributes

Attribute Description Data type Required Default value
Subkey The subkey to create under the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ServiceName\Parameters key. A string between 1 and 255 characters in length that cannot start or end with a period or contain these characters: <, >, :, ", /, \, , ?, or *. Yes

Child Elements

None.

Parent Elements

Parent Element Description
serverpreview:ServiceParameters Specifies a set of parameters to configure for the service. These parameters correspond to registry values that are created under the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ServiceName\Parameters key.

Examples

<Package ...
         xmlns:serverpreview=http://schemas.microsoft.com/appx/manifest/serverpreview/windows10"  
         IgnorableNamespaces="... serverpreview">
    <Applications>
       <Application Id="TestService">
            <uap:VisualElements AppListEntry="none" 
                                DisplayName="TestService" 
                                Square150x150Logo="logo.png" 
                                Square44x44Logo="logo.png" 
                                Description="TestService" 
                                BackgroundColor="#777777"/>
            <Extensions>
                <serverpreview:Extension Category="windows.ntServices">  
                    <serverpreview:NTServices>  
                        <serverpreview:NTService  
                                Name="serviceName"  
                                Executable="depServiceExec.exe"                  
                                StartupType="auto"  
                                StartAccount="networkService"  
                                DisplayName="depServiceName" >  
                            <serverpreview:ServiceParameters>  
                                <serverpreview:ServiceParameterKey 
                                        Subkey="key1\key2"/>  
                            </serverpreview:ServiceParameters>                      
                        </serverpreview:NTService> 
                    </serverpreview:NTServices>  
                </serverpreview:Extension>  
            </Extensions>
        </Application>
    </Applications>
</Package>

Requirements

Namespace http://schemas.microsoft.com/appx/manifest/serverpreview/windows10