This is a slight variation of this question. If I have a function that performs an action that returns a value but I did not capture that value in a variable, is there any way I can get that value while stepping through with the debugger without running the function a 2nd time in the immediate window?
A practical example
using (SqlConnection cnSqlConnect = OpenConnection(ConnectionString))
using (SqlCommand sqlCmd = new SqlCommand(command, cnSqlConnect))
{
sqlCmd.ExecuteNonQuery();
}
Is there any way to get the value of sqlCmd.ExecuteNonQuery()
without running it twice?