Cannot instantiate PowerShell V5 object: 80070002

This forum can be browsed by the general public. Posting is limited to current SAPIEN license holders with active maintenance and does not offer a response time guarantee.
Forum rules
DO NOT POST LICENSE NUMBERS, ACTIVATION KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
This topic is 5 years and 9 months old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
User avatar
michaelbhansen
Posts: 10
Last visit: Mon Nov 12, 2018 12:50 am

Re: Cannot instantiate PowerShell V5 object: 80070002

Post by michaelbhansen »

No, nothing is added to neither Application or System log. Mind that the script runs without issues in Powershell console (and using the ISE). The error only occurs when trying the run the script in Powershell Studio GUI.

Powershell Studio is installed from the latest installer package available in "Registered Software Licenses" under "Account: Registered Products". Default installation is performed. To me it looks like a compatibility issue with Windows 10.

Br. Michael.
User avatar
Alexander Riedel
Posts: 8479
Last visit: Thu Mar 28, 2024 9:29 am
Answers: 19
Been upvoted: 37 times

Re: Cannot instantiate PowerShell V5 object: 80070002

Post by Alexander Riedel »

PowerShell Studio 2016 normally runs fine on Windows 10.
You could run ILSpy on your machine (attached) and load the dll you registered and see if it reports anything missing.
Attachments
ILSpy_binaries_3.1.0.3652.zip
(1.8 MiB) Downloaded 64 times
Alexander Riedel
SAPIEN Technologies, Inc.
User avatar
michaelbhansen
Posts: 10
Last visit: Mon Nov 12, 2018 12:50 am

Re: Cannot instantiate PowerShell V5 object: 80070002

Post by michaelbhansen »

I tried to load all three PWSHHelpCtrl2016* binaries. None caused reports of anything missing.
User avatar
Alexander Riedel
Posts: 8479
Last visit: Thu Mar 28, 2024 9:29 am
Answers: 19
Been upvoted: 37 times

Re: Cannot instantiate PowerShell V5 object: 80070002

Post by Alexander Riedel »

We verified on a standard Windows 10 VM that SPS 2016 runs fine and can execute script normally.
Do you have another machine accessible you can try this on?
Alexander Riedel
SAPIEN Technologies, Inc.
User avatar
michaelbhansen
Posts: 10
Last visit: Mon Nov 12, 2018 12:50 am

Re: Cannot instantiate PowerShell V5 object: 80070002

Post by michaelbhansen »

I might be able to install it on a work laptop. But it is on this computer I need to use the graphical script. Is it painless to move the form-based script from where it was developed, to a PC without a (working) copy of Powershell Studio?
User avatar
davidc
Posts: 5913
Last visit: Mon Jul 08, 2019 8:55 am
Been upvoted: 2 times

Re: Cannot instantiate PowerShell V5 object: 80070002

Post by davidc »

You can export the GUI script (Ribbon->Deploy->Export->Export to File) or package it into an executable.
David
SAPIEN Technologies, Inc.
User avatar
michaelbhansen
Posts: 10
Last visit: Mon Nov 12, 2018 12:50 am

Re: Cannot instantiate PowerShell V5 object: 80070002

Post by michaelbhansen »

I now have the problem solved. I uninstalled the software, removed all folders under ProgramData- and UserData-folders, that mentioned Sapien in their name. I also did a thorough cleanup of the registry, removing all references to Sapien. A bit over the top, perhaps, but after this I reinstalled Powershell Studio, and now it works as expected.

May I suggest that you create a post on the correct way to do a full cleanup after removing the software?

Thanks for your assistance, Alexander.

Br. Michael.
This topic is 5 years and 9 months old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.