Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VBScript is deprecated #282

Closed
Acters opened this issue Oct 11, 2023 · 10 comments
Closed

VBScript is deprecated #282

Acters opened this issue Oct 11, 2023 · 10 comments

Comments

@Acters
Copy link

Acters commented Oct 11, 2023

As of right now, there are a lot of references and uses in the scripts to slmgr.vbs and ospp.vbs for activation and checking status.
How will this be handled once future releases of windows remove VBScript functionality? (Windows 11 allows for VBS to be optionally removed)
Will the MAScripts transition to PowerShell script alternatives?

@WindowsAddict
Copy link
Member

It's already using WMI directly instead of slmgr.vbs tool for activation-related commands. In very few places, the script relies on slmgr.vbs, we can easily add alternative commands.
Furthermore, I don't think they will make it unavailable by default, they will most likely treat it as they did with wmic.exe, available by default but can be removed.

@Tragen
Copy link

Tragen commented Oct 11, 2023

The newest Windows 11 installations have it disabled by default and can enable it if needed.
We will see if it's needed. I used it often for small things. It was nice and easy.

@WindowsAddict
Copy link
Member

@Tragen they did the same thing with wmic.exe as well, at first in insider builds they removed it but later in public release, they added it back and made it available by default.

@Meyers07
Copy link

Just a suggestion, when the time come where VBS didn't became part of Windows anymore, there should be either:
-a guide to users to install VBS again
-a drop in replacement for VBS commands
because as i see most of the codes still rely on slmgr vbs and i often use older apps (such as game mod tools) that rely on VBS.

@WindowsAddict
Copy link
Member

@Meyers07 so far vbs is not removed in any insider build of Windows. I'll replace all the vbs codes with wmi/powershell in next update of MAS.

@kdejeqq
Copy link

kdejeqq commented Nov 19, 2023 via email

@Meyers07
Copy link

Meyers07 commented Nov 19, 2023

@Meyers07 so far vbs is not removed in any insider build of Windows. I'll replace all the vbs codes with wmi/powershell in next update of MAS.

Nice idea though keep provide fallback methods (as in the methods that still use vbs) as within Windows itself, the method how to see license types verbosely can only be done thru slmgr vbs, let me know if powershell can do slmgr too.

@WindowsAddict
Copy link
Member

@Meyers07 so far vbs is not removed in any insider build of Windows. I'll replace all the vbs codes with wmi/powershell in next update of MAS.

Nice idea though keep provide fallback methods (as in the methods that still use vbs) as within Windows itself, the method how to see license types verbosely can only be done thru slmgr vbs, let me know if powershell can do slmgr too.

Every use of slmgr.vbs can be replaced by wmi/powershell in the script.

@Acters
Copy link
Author

Acters commented Nov 21, 2023

It's already using WMI directly instead of slmgr.vbs tool for activation-related commands. In very few places, the script relies on slmgr.vbs, we can easily add alternative commands. Furthermore, I don't think they will make it unavailable by default, they will most likely treat it as they did with wmic.exe, available by default but can be removed.

The bigger idea is to move towards deprecating all VBS related functions and calls as there are PS equivalents of both slmgr.vbs and ospp.vbs capabilities that can be used instead without regressions or loss of function. I am glad to hear these scripts will be replaced.

Someone made a "drop in" replacement to the usual scripts that made use of slmgr.vbs functions. The major command doing the heavy lifting is the new CIM, Get-CimInstance. Found here: https://gist.github.com/zbalkan/4ba92656a3a8387e6b220bcf8fcd5fc6

Only difference between WMI and CIM is on how it communicates with remote systems. WMI is allegedly deprecated because it is windows only, while CIM can be multiplatform.

OSPP is similar but it is specific to office. The Get-CimInstance command can still work for this purpose. website with decent documented Powershell equivalents https://woshub.com/checking-office-2016-365-activation-status/

@WindowsAddict
Copy link
Member

Looks like they have dropped the idea of removing VBS support by default in the upcoming RTM build, its available by default. VBS uses will be removed from MAS anyway, closing this issue here now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants
@Tragen @Acters @WindowsAddict @kdejeqq @Meyers07 and others