I create a new file in powershell ISE, it's run perfectly but I face a bit issue I can't add break point
Am I doing things wrongly !?
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It only takes a minute to sign up.Sign up to join this community
I think you didn't save your script till now. so You should first save your file to be able to set a breakpoint.
Note: You can set three types of breakpoints using (F9) in the Windows PowerShell debugging environment:
Line breakpoint. The script pauses when the designated line is reached during the operation of the script
Variable breakpoint. The script pauses whenever the designated variable’s value changes.
Command breakpoint. The script pauses whenever the designated command is about to be run during the operation of the script. It can include parameters to further filter the breakpoint to only the operation you want. The command can also be a function you created.
For more details check How to Debug Scripts in Windows PowerShell ISE
Using Windows powershell ISE, you can debug the powershell scripts. Windows Powershell ISE tool come along with the installation of windows server 2012.
To debug the script select the line of code where you want to place the breakpoint and then go to "
Debug" menu option and click on "
Toggle BreakPoint" or
F9. This will add the breakpoint. -
When you execute the script by pressing F5 keyword, once it hits the breakpoint you can debug the scripts
Msdn Reference Link How to Debug Scripts in Windows PowerShell ISE