Hello,
- Check the PowerShell configuration file.
Run to see the contents of the current profile: Get-Content $PROFILE
Look for any commands that might interfere with or load modules that might override the default behavior.
- Test in a new user profile.
Create a new user profile and test if the issue persists. This can help determine if the issue is specific to your current user profile.
- Review the event log.
Check the Windows event log for any related errors or warnings that may provide more clues.
- Reset PowerShell settings.
As a last resort, you can reset the PowerShell settings to their defaults. Note that this will remove any customizations you have made. Use the following command:
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\PowerShell\1\PowerShellEngine" -Name "*"
Hope this helps.
Best Regards,
Hania Lian
============================================
If the Answer is helpful, please click "Accept Answer" and upvote it.