Ustaw koszt: wartość rejestru CostKomputerHKLM\Software\Policies\Microsoft\Windows\Wireless\NetCost
- Identyfikator zasady
- SetCost
- Zakres
- Konfiguracja komputera
- Obsługiwane w systemach
- Co najmniej system Windows Server 2012, Windows 8 lub Windows RT
- Źródło
- Administrative Templates (.admx) for Windows 11 2026 Update (26H2) (wersja 1.0)
- Kategoria
- Sieć › Usługa sieci WLAN › Koszt użycia sieci WLAN
Rejestr
Cost
REG_DWORDKomputer- Wartość włączona
- Zależy od wartości opcji
- Element
- Wybierz wartość kosztu połączenia z siecią WLAN, która ma zostać ustawiona:
| Pozycja | Zapisana wartość |
|---|---|
| Bez ograniczeń | 1 |
| Stały | 2 |
| Zmienny | 3 |
Zastosuj przez .reg · CMD · PowerShell
.reg
Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Wireless\NetCost] ; Opcje (użyj tylko jednej) ; Bez ograniczeń "Cost"=dword:00000001 ; Stały "Cost"=dword:00000002 ; Zmienny "Cost"=dword:00000003
CMD
:: Opcje (użyj tylko jednej) :: Bez ograniczeń reg add "HKLM\Software\Policies\Microsoft\Windows\Wireless\NetCost" /v "Cost" /t REG_DWORD /d 1 /f :: Stały reg add "HKLM\Software\Policies\Microsoft\Windows\Wireless\NetCost" /v "Cost" /t REG_DWORD /d 2 /f :: Zmienny reg add "HKLM\Software\Policies\Microsoft\Windows\Wireless\NetCost" /v "Cost" /t REG_DWORD /d 3 /f
PowerShell
# Wspólne: utwórz klucz New-Item -Path 'HKLM:\Software\Policies\Microsoft\Windows\Wireless\NetCost' -Force | Out-Null # Opcje (użyj tylko jednej) # Bez ograniczeń New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Wireless\NetCost' -Name 'Cost' -PropertyType DWord -Value 1 -Force | Out-Null # Stały New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Wireless\NetCost' -Name 'Cost' -PropertyType DWord -Value 2 -Force | Out-Null # Zmienny New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Wireless\NetCost' -Name 'Cost' -PropertyType DWord -Value 3 -Force | Out-Null