> For the complete documentation index, see [llms.txt](https://docs.devolutions.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.devolutions.net/powershell/it/powershell-commands/set-rdmtask.md).

# Set-RDMTask

### Sinossi

Salva o aggiorna un'attività.

### Sintassi

#### \_\_AllParameterSets

```
Set-RDMTask [-Task] <PSTask> [-Comment <string>] [-Description <string>] [-DueDate <datetime>]
 [-Force] [-Name <string>] [-Priority <int>] [-Status <string>] [-UnassignUser] [-User <Object>]
 [-ForcePromptAnswer <DialogResult[]>] [-WhatIf] [-Confirm] [<CommonParameters>]
```

### Descrizione

Salva o aggiorna un'attività dello spazio di lavoro corrente. Questa funzionalità è disponibile solo per i seguenti spazi di lavoro: Devolutions Server, Azure SQL, SQL Server e SQLite. Se lo spazio di lavoro non supporta gli utenti, il parametro User verrà semplicemente ignorato. Se è coinvolta una cartella virtuale, l'utente deve disporre dei diritti di aggiunta e modifica per salvare le attività. Per modificare i campi, è possibile utilizzare i parametri di questo cmdlet oppure modificare direttamente il PSTask. L'impatto della conferma (ConfirmImpact) è basso.

### Esempi

#### Esempio 1

```powershell
PS C:\> Get-RDMTask -Name ATask | Set-RDMTask -Comment "Task completed" -Status Closed
```

Aggiunge il commento "Task completed" all'attività ATask e la chiude. Se il nome non è univoco, tutte le attività denominate ATask riceveranno le modifiche.

#### Esempio 2

```powershell
PS C:\> New-RDMTask -Name ATask -Entry AnEntry | Set-RDMTask -Force
```

Salva un'attività appena creata denominata ATask e associata ad AnEntry senza alcuna richiesta di conferma.

#### Esempio 3

```powershell
PS C:\> $user = Get-RDMUser -Name AUser; Get-RDMTask -Status Assigned -User $user | Set-RDMTask -UnassignUser
```

Annulla l'assegnazione di tutte le attività assegnate all'utente AUser.

#### Esempio 4

```powershell
PS C:\> $task = Get-RDMTask -Name ATask; $task.Task.CustomField1 = "Whatever"; Set-RDMTask $task
```

Memorizza l'attività dal nome univoco ATask in $task. Aggiunge un valore a CustomField1 e salva la modifica utilizzando l'unico parametro posizionale.

#### Esempio 5

```powershell
PS C:\> Get-RDMTask -Name ATask | Set-RDMTask $task -WhatIf -Verbose -Description 'NewDesc' -DueDate 2023/1/1 -Priority 3
```

Utilizzando i parametri WhatIf e Verbose, sarà possibile determinare se l'attività viene creata o aggiornata e dove esattamente (nome dello spazio di lavoro > nome della voce > nome dell'attività). Non verrà apportata alcuna modifica.

### Parametri

#### -Comment

Modifica il commento dell'attività.

```yaml
Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### -Confirm

Richiede una conferma prima di eseguire il cmdlet.

```yaml
Type: System.Management.Automation.SwitchParameter
DefaultValue: False
SupportsWildcards: false
Aliases:
- cf
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### -Description

Modifica la descrizione dell'attività.

```yaml
Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### -DueDate

Specifica la scadenza entro cui completare l'attività.

```yaml
Type: System.Nullable`1[System.DateTime]
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### -Force

L'attività verrà salvata o creata senza conferma.

```yaml
Type: System.Management.Automation.SwitchParameter
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### -ForcePromptAnswer

Switch da usare con cautela. Risponderà automaticamente alle richieste che pongono domande sì/no, sì/no/annulla oppure ok/annulla. In caso di più richieste, è possibile passare più valori a questo parametro. Ecco i valori accettati:

* Yes: accetta la richiesta. Copre i valori OK e Automatic.
* No: rifiuta la richiesta sì/no/annulla. "Cancel" è l'opzione di fallback se non è presente l'opzione "No".
* Cancel: annulla la richiesta sì/no/annulla. "No" è l'opzione di fallback se non è presente l'opzione "Cancel".

```yaml
Type: System.Windows.Forms.DialogResult[]
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### -Name

Nuovo nome per l'attività.

```yaml
Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: true
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### -Priority

Modifica la priorità dell'attività.

```yaml
Type: System.Nullable`1[System.Int32]
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### -Status

Modifica lo stato dell'attività.

```yaml
Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### -Task

Attività da aggiungere o modificare.

```yaml
Type: RemoteDesktopManager.PowerShellModule.PSOutputObject.PSTask
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: 0
  IsRequired: true
  ValueFromPipeline: true
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### -UnassignUser

Rimuove l'utente assegnato all'attività.

```yaml
Type: System.Management.Automation.SwitchParameter
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### -User

Assegna questo utente all'attività. L'utente può essere specificato con il proprio nome, indirizzo email, ID o con un PSUserInfo.

```yaml
Type: System.Object
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### -WhatIf

Mostra cosa accadrebbe se il cmdlet venisse eseguito. Il cmdlet non viene eseguito.

```yaml
Type: System.Management.Automation.SwitchParameter
DefaultValue: False
SupportsWildcards: false
Aliases:
- wi
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
```

#### CommonParameters

Questo cmdlet supporta i parametri comuni: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction e -WarningVariable. Per maggiori informazioni, consulti [about\_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216).

### Input

#### RemoteDesktopManager.PowerShellModule.PSOutputObject.PSTask

L'attività ottenuta da Get-RDMTask può essere inviata tramite pipe al parametro Task.

### Note

Per maggiori informazioni, digiti "Get-Help Set-RDMTask -detailed". Per informazioni tecniche, digiti "Get-Help Set-RDMTask -full".


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.devolutions.net/powershell/it/powershell-commands/set-rdmtask.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
