How to change the value of a variable when debugging Java code in NetBeans 7.1?

I set a breakpoint that allows me to see the value in the field on the object. I would like to change the value and then continue execution, but then I will try to change the value from the variable view, the value field is grayed out. Is there a way to change the values ​​of variables during debugging?

+5
source share
2 answers

It is also possible to change the value of primitive variables and rows in place in the Value column of the Variables window. To change the values ​​of the Object variables, you can use "Evaluate Expression ..." in the "Debug" menu (Ctrl + F9).

+17
source

, Apply Code Changes Debug. , , .

JAVA , "" "", " Java", " ", "".

+4

All Articles