MScholtes / PSVirtualDesktop

VirtualDesktop is a Powershell module that provides commandlets to manage virtual desktops of Windows 10.
MIT License
304 stars 18 forks source link

Set-DesktopName no longer functional #9

Closed SinnGit closed 3 years ago

SinnGit commented 3 years ago

I caught the comment in another open issue that Set-DesktopName was not functioning in Powershell Core. It seems that Set-DesktopName is no longer functional for older versions of Powershell either. No errors whatsoever, the cmdlet acts as if it has made a change, but never actually does so.

PS C:\Users> Set-DesktopName -Name "Excel" -desktop 1 PS C:\Users> Get-DesktopList

Number Name Visible


 0 Desktop 1    True
 1 Desktop 2   False
 2 Desktop 3   False
 3 Desktop 4   False
 4 Desktop 5   False
 5 Desktop 6   False

PS C:\Users> get-host | select version

Version

5.1.18362.1171

PS C:\Users> get-module virtualdesktop | select version

Version

1.3.0

MScholtes commented 3 years ago

Hello SinnGit,

for most of the functions of PSVirtualDesktop an underlying function of the Windows API is used, so it is with the function Set-DesktopName. But the feature to name desktops was introduced to Windows first with Windows 10 version 20H1 (and you are running Windows 10 version 1903), if you want to use it, you have to update your Windows.

Greetings

Markus

SinnGit commented 3 years ago

Hi Markus,

Thanks, I'm actually running 1909 on this system, but it doesn't look like that will cut it either. I will get this tested again with the correct version.

Thanks

MScholtes commented 3 years ago

Hello SinnGit,

OK, I understand. Microsoft did not update Powershell when they updated Windows 10 1903 (Build 18362) to 1909 (Build 18363). So the Powershell version led me to the wrong version of the Windows you're using.

But this doesn't change the reason and solution for the issue.

Greetings

Markus

MScholtes commented 3 years ago

Closed due to no response for several weeks