To clear a breakpoint, right-click the breakpoint icon and select Clear Breakpoint from the context
menu. Alternatively, you can press the F12 key to clear the breakpoint.
To clear a breakpoint programmatically, use the dbclear function. For example, to clear the
breakpoint at line six in a file called myprogram.m, type:
dbclear in myprogram at 6
To clear all breakpoints in the file, right-click the breakpoint alley and select Clear All Breakpoints
in File. You can also use the dbclear all command. For example, to clear all the breakpoints in a
file called myprogram.m, type:
dbclear all in myprogram
To clear all breakpoints in all files, including error breakpoints, right-click the breakpoint alley and
select Clear All Breakpoints. You also can use the dbclear all command.
Breakpoints clear automatically when you end a MATLAB session. To save your breakpoints for future
sessions, use the dbstatus function.
See Also
Related Examples
•
“Debug MATLAB Code Files” on page 22-2
•
“Examine Values While Debugging” on page 22-14
Set Breakpoints
22-13
menu. Alternatively, you can press the F12 key to clear the breakpoint.
To clear a breakpoint programmatically, use the dbclear function. For example, to clear the
breakpoint at line six in a file called myprogram.m, type:
dbclear in myprogram at 6
To clear all breakpoints in the file, right-click the breakpoint alley and select Clear All Breakpoints
in File. You can also use the dbclear all command. For example, to clear all the breakpoints in a
file called myprogram.m, type:
dbclear all in myprogram
To clear all breakpoints in all files, including error breakpoints, right-click the breakpoint alley and
select Clear All Breakpoints. You also can use the dbclear all command.
Breakpoints clear automatically when you end a MATLAB session. To save your breakpoints for future
sessions, use the dbstatus function.
See Also
Related Examples
•
“Debug MATLAB Code Files” on page 22-2
•
“Examine Values While Debugging” on page 22-14
Set Breakpoints
22-13
