New-NAVServerConfiguration

New-NAVServerConfiguration

Creates a new configuration with default values, or to replace the existing configuration for a Microsoft Dynamics NAV Server instance.

Syntax

Parameter Set: DefaultServerSettingsDocument
New-NAVServerConfiguration [-Force] [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: __AllParameterSets
New-NAVServerConfiguration [[-ServerInstance] <String> ] [-Force] [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: NewServerSettingsDocument
New-NAVServerConfiguration [-Force] [-ServerSettingsDocument <XmlNode> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

Detailed Description

Use the New-NAVServerConfiguration cmdlet to create a new configuration with default values, or to replace the existing configuration for a Microsoft Dynamics NAV Server instance.

Use the New-NAVServerConfiguration cmdlet without arguments to create a new configuration with default values. The cmdlet returns an XML document that contains default configuration settings for a Microsoft Dynamics NAV Server instance.

Use New-NAVServerConfiguration with the -ServerInstance and -ServerSettingsDocument parameters to replace the existing configuration for a Microsoft Dynamics NAV Server instance.

Parameters

-ServerInstance<String>

Specifies the name of a Microsoft Dynamics NAV Server instance. The default instance name is DynamicsNAV71. You can specify either the full name of an instance such as MicrosoftDynamicsNavServer$myinstance or the short name such as myinstance.

If you specify a Microsoft Dynamics NAV Server instance, the configuration replaces the current configuration for that instance. A new CustomSettings.config file is created in the service directory for the instance, overwriting any existing CustomSettings.config file.

Aliases

none

Required?

false

Position?

1

Default Value

none

Accept Pipeline Input?

True (ByValue, ByPropertyName)

Accept Wildcard Characters?

false

-ServerSettingsDocument<XmlNode>

Specifies the Microsoft Dynamics NAV Server instance configuration document in XML format. You cannot specify a ServerSettingsDocument unless you also specify a ServerInstance. For more information, see Example 2.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByValue, ByPropertyName)

Accept Wildcard Characters?

false

-Force

Forces the command to run without asking for user confirmation.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Confirm

Prompts you for confirmation before running the cmdlet.

Required?

false

Position?

named

Default Value

false

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Required?

false

Position?

named

Default Value

false

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see about_CommonParameters.

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

  • None or System.String

    You can pipe a string that contains a Microsoft Dynamics NAV Server instance name or the Microsoft Dynamics NAV Server instance configuration XML document to the cmdlet.

Outputs

The output type is the type of the objects that the cmdlet emits.

  • System.Xml.XmlDocument

    Returns the configuration information as an XML document.

Examples

-------------------------- EXAMPLE 1 --------------------------

Description

-----------

This example returns an XML document that contains the default configuration details for a Microsoft Dynamics NAV Server instance.

C:\PS>New-NAVServerConfiguration | fc