> 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-universal/da/udvikling/editor.md).

# Editor

Få mere at vide om, hvordan editoren i PowerShell Universal leverer IntelliSense, kodeformatering, fremhævning af syntaksfejl og integration med PSScriptAnalyzer.

Editorfunktionerne i PowerShell Universal-admin console giver en omfattende redigeringsoplevelse for PowerShell-brugere. De vil kunne drage fordel af IntelliSense, formatering og support til parserfejl.

## IntelliSense

Alle editorer i PowerShell Universal vil give IntelliSense. De bør kunne autofuldføre kommandoer, parametre, indbyggede variabler og stier.

Der er et par forbehold ved IntelliSense.

**IntelliSense kører i PowerShell Universal-serveren**

Det er ikke afhængigt af et konfigureret miljø for at fungere. Det kører i PowerShell-serverprocessen og bruger derfor den aktuelle version af PowerShell 7, som serveren refererer til.

**Universal-moduler er tilgængelige**

Moduler, der leveres med PowerShell Universal, inkluderes automatisk. De vil se IntelliSense for følgende moduler.

* Universal

**Moduler, der er inkluderet i PSModulePath, er tilgængelige**

Ethvert modul, der er installeret i en PSModulePath, vil være tilgængeligt i IntelliSense.

**Live-variabler understøttes ikke**

De vil have adgang til indbyggede variabler som `ConfirmPreference` og `Host`, men De vil ikke se variabler, der er specifikke for PowerShell Universal.

## Formatering

[Formatering](https://devolutions.net/blog/)

De kan bruge kommandoen `Invoke-Formatter` fra `PSScriptAnalyzer` i Deres scripts. De skal installere `PSScriptAnalyzer` i Deres PSModulePath for at bruge denne funktionalitet. De kan formatere ved at højreklikke i editoren og vælge Format eller ved at trykke på F8.

## Syntaksfejl

Syntaksfejl vises som røde bølgestreger i editoren. Når De holder markøren over dem, vises oplysninger om, hvorfor syntaksfejlen er til stede.

## PSScriptAnalyzer-integration

PowerShell Universal-editoren integrerer automatisk med PSScriptAnalyzer, når det er installeret på PSU-serveren. PSScriptAnalyzer køres mod PowerShell-scripts, mens De skriver dem i Admin Console. Advarsler vises inline samt som en meddelelse øverst i editoren.

Klik på alerten for at blive navigeret til den første fejl eller advarsel.

Fra og med version 4.1 kan De nu angive en [PSScriptAnalyzerSettings.psd1](https://learn.microsoft.com/en-us/powershell/utility-modules/psscriptanalyzer/using-scriptanalyzer?view=ps-modules) i roden af Deres lager for at muliggøre konfiguration af analysen i PowerShell Universal.


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.devolutions.net/powershell-universal/da/udvikling/editor.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
