Share via


Set-NAVServerPermission

Changes the values for an existing permission set.

Syntax

Default (Default)

Set-NAVServerPermission
    -PermissionSetId <String>
    -ObjectType <ObjectType>
    -ObjectId <Int32>
    [-SecurityFilter <String>]
    [-Read <PermissionOption>]
    [-Insert <PermissionOption>]
    [-Modify <PermissionOption>]
    [-Delete <PermissionOption>]
    [-Execute <PermissionOption>]
    [-ServerInstance] <String>
    [-Force]
    [-WhatIf]
    [-Confirm]
    [<CommonParameters>]

Description

Use the Set-NAVServerPermission cmdlet to change the permissions that are granted by an existing permission set.

Examples

EXAMPLE 1

Set-NAVServerPermission BC -PermissionSetId BASIC -ObjectType Page -ObjectId 21 -Read Indirect

This example updates the Read permission for the specified page object to Indirect for the BASIC permission set.

Parameters

-Confirm

Prompts you for confirmation before executing the command.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False
Aliases:cf

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Delete

Specifies the delete permission for the object. You can use either a string value (such as No) or a numeric value (such as 0).

No = 0

Yes = 1

Indirect = 2

Parameter properties

Type:PermissionOption
Default value:None
Accepted values:No, Yes, Indirect
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Execute

Specifies the execute permission for the object. You can use either a string value (such as No) or a numeric value (such as 0).

No = 0

Yes = 1

Indirect = 2

Parameter properties

Type:PermissionOption
Default value:None
Accepted values:No, Yes, Indirect
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Force

Forces the command to run without asking for user confirmation.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Insert

Specifies the insert permission for the object. You can use either a string value (such as No) or a numeric value (such as 0).

No = 0

Yes = 1

Indirect = 2

Parameter properties

Type:PermissionOption
Default value:None
Accepted values:No, Yes, Indirect
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Modify

Specifies the modify permission for the object. You can use either a string value (such as No) or a numeric value (such as 0).

No = 0

Yes = 1

Indirect = 2

Parameter properties

Type:PermissionOption
Default value:None
Accepted values:No, Yes, Indirect
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ObjectId

Specifies the ID of the object that the permission applies to.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ObjectType

Specifies the type of the object the permission applies to. You can use either a string value (such as TableData) or a numeric value (such as 0).

TableData = 0

Table = 1

Form = 2

Report = 3

Dataport = 4

CodeUnit = 5

XmlPort = 6

MenuSuite = 7

Page = 8

Query = 9

System = 10

FieldNumber = 11

Parameter properties

Type:ObjectType
Default value:None
Accepted values:TableData, Table, Form, Report, Dataport, CodeUnit, XmlPort, MenuSuite, Page, Query, System, FieldNumber, LimitedUsageTableData, TablePage, PageExtension, TableExtension, Enum, EnumExtension, Profile, ProfileExtension, PermissionSet, PermissionSetExtension, ReportExtension, ExternalBusinessEvent, DynamicQuery, MovedObjectManifest
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-PermissionSetId

The ID of the permission set that you are updating, such as BASIC or SUPER.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Read

Specifies the read permission for the object. You can use either a string value (such as No) or a numeric value (such as 0).

No = 0

Yes = 1

Indirect = 2

Parameter properties

Type:PermissionOption
Default value:None
Accepted values:No, Yes, Indirect
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-SecurityFilter

Specifies a security filter for the permission.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ServerInstance

Specifies the name of a Business Central Server instance, for example, BC or myinstance. You can specify either the full name of an instance, such as MicrosoftDynamicsNavServer$myinstance or the short name such as myinstance.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:0
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:True
Value from remaining arguments:False

-WhatIf

Describes what would happen if you executed the command without actually executing the command.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False
Aliases:wi

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Inputs

System.String

You can pipe a string that contains a Business Central Server instance name to the cmdlet.

Outputs

None