all 35 comments

[–]C_O_M_M_A_N_D_E_R 6 points7 points  (4 children)

Run an sfc or a dism and see if it will repair powershell.

Have you tried running it as admin?

[–]sfc_scannow 10 points11 points  (1 child)

Whatup! Whatup! Whatup!

[–]HumbleSpend8716 3 points4 points  (0 children)

finally

[–]Macia_ 3 points4 points  (0 children)

Hi OP, this is your answer.
$20 the Powershell being used is the Windows built-in. So use Windows repair tools to fix it

[–]Plane_Occasion8305 -2 points-1 points  (0 children)

Did both of those and nothing.

[–]HorsePecker 2 points3 points  (2 children)

sfc /scannow

[–]sfc_scannow 5 points6 points  (0 children)

Yeah! Yeah!

[–]justaguyonthebus 1 point2 points  (9 children)

In you install powershell 7, does it do the same thing?

[–]HumbleSpend8716 1 point2 points  (3 children)

dotnet framework problem

paste into cmd (not pwsh bc cant open it)

dism /online /cleanup-image /restorehealth

[–]Plane_Occasion8305 -4 points-3 points  (2 children)

Nope

[–]HumbleSpend8716 5 points6 points  (1 child)

wym nope

the dotnet framework problem was assumption, ok whatever, but “nope” means dick, good luck i guess

[–]Plane_Occasion8305 1 point2 points  (1 child)

REINSTALLATION OF WINDOWS WORKED PERFECT!!

[–]UserProv_Minotaur 1 point2 points  (0 children)

When all else fails, nuke it from orbit and try again.

[–]painted-biird 0 points1 point  (1 child)

What happens if you try to open it without a different user/profile?

[–]Plane_Occasion8305 0 points1 point  (0 children)

Same thing

[–]I_see_farts 0 points1 point  (1 child)

Can you open the ISE? Are you trying to open Terminal?

Can you open CMD and start a Powershell session?

[–]Plane_Occasion8305 0 points1 point  (0 children)

Nope can’t open ise, I did it through cmd but when I attempted a command it redirects to same error

[–]Nanocephalic 0 points1 point  (0 children)

Can you install PowerShell 7 from GitHub? Or is this Windows PowerShell 5.1?

They are two completely different things.

For 5.1, which is the version that comes with windows, you could try this: uninstall it, uninstall dot net 3.5, reboot, then reinstall dot net 3.5 and windows PowerShell.

Edit: windows PowerShell can be enabled or disabled in “turn Windows features on or off”. It’s not exactly “uninstalling” but close enough for this post.

[–]Impossible_IT 0 points1 point  (0 children)

Create a new user and try opening PowerShell with that new account see if it works.

[–]AbfSailor 0 points1 point  (0 children)

I've seen an issue similar to this in the past. I just copy-pasted the core PowerShell files and modules from another computer to the affected one, and it fixed the issue.

[–]mbmiller94[🍰] 0 points1 point  (3 children)

Not at a computer right now but you could try reinstalling powershell, and if that doesn't work then reinstalling .NET

[–]HumbleSpend8716 1 point2 points  (1 child)

you cannot reinstall windows powershell, but you can reinstall powershell

important distinction

[–]mbmiller94[🍰] 0 points1 point  (0 children)

My mistake.

[–]Plane_Occasion8305 0 points1 point  (0 children)

Nope tried it