What you'e seeing in some cases is what's called "defensive programming"; e.g.
One assumes that if Y == 0, the ball is at "ground level"; and if Y = Height of container, it is "on the ceiling".
However, with "floating point calculations" (or some "logic"), you may never reach zero or height exactly; so one plays it safe by coding "(equal or) greater / less than" versus an "exact" value that might be missed.
In this case, the code goes or projects going "past" some "stopping point".
"(I) am amazed to see myself here rather than there ... now rather than then".
― Blaise Pascal
But when I try and register the shellwindow it tells me that the Container does not exist. I assumed they changed something so my question is if you are not supposed to use the Bootstrapper container at all? I can register types with the code:
I have a windows forms application that has a form that uses Form1.ShowDialog(this); to open a child form. The problem is that when an exception occurs in my child form, all i get back in the output window of Visual Studio 2017 is
Thanks for the reply! I wasn't sure which window was the exception helper, as I (stupidly) have not given exception handling and debugging the priority it deserves. So this helps me better state the problem. The Exception Helper is not showing up inline, next to my code, for exceptions that occur in the child dialog. It's just throwing the exception back to the caller in the parent window. No exception helper window opens and the application continues in the running state.
I checked my settings to make sure that Exception Helper is still enabled in Options > Debugging > General > Use the new Exception Helper.
I see. Well what you should do is trap the exception with a try/catch block. Then place a breakpoint inside the catch block and examine the exception object. It will include all the information in there. Hope this helps!
// Code that throws exceptions
catch (Exception e)
e.ToString(); // Put breakpoint here and use the debugger to examine the exception object
The difficult we do right away...
...the impossible takes slightly longer.
Issue Resolved, thanks in part to your suggestion.
Here's how I fixed it.
This is probably overkill, but for my own learning, I created this method to output stacktrace and other exception info to the output window. It did the trick. I can see, just form the exception's StackTrace property:
Now, I'm seeing this in the Output window:
EXCEPTION StackTrace: at TreeView.frmResources.DropTargetListBox_DragDrop(Object sender, DragEventArgs e) in D:\xxx\TreeView\frmResources.cs:line 255
var result = from tab in dt.AsEnumerable()
group tab by new
ID_Gaminio = tab.Field<int>("Id_gaminio"),
Nr_Pcb = tab.Field<int>("Nr_pcb"),
Pavadinimas_M = tab.Field<string>("Pavadinimas_M"),
Data_surinkimo = tab.Field<datetime>("Data_surinkimo"),
Pavadinimas_gam = tab.Field<string>("Pavadinimas_g")