I have narrowed down a previous problem to the following more specific
items:
1) I have my startup object in VB.NET (VS 2003) set to Sub Main().
2) Inside of Sub Main() I do a "Application.Run(MyMainForm)"
3) Inside of MyMainForm_Load I create an object, ie: "poMyObj=new clsMyObj"
4) Within poMyObj I create a new System.Threading.Timer instance. I use a
delegate with AddressOf to fire a certain function whenever the timer fires
(the function
is called MyFunction(), and works fine).
5) Everything works like a charm!
6) HOWEVER: Inside the timer callback function (ie: the MyFunction()
function) I place a
breakpoint. When the debugger stops I try to display any labels from
MyMainForm and
just referencing them cause VB.NET to hang. This problem only occurs when
the debugger
trys to reference controls on the form. If I don't use the debugger the
controls can be
referenced by the object's VB code just fine - updating and refreshing data.
Why can't the debugger access the form's controls but everything else can?
Note: when
the problem is occurring I can display any local program variable values,
but I can't
display anything from the form unless I do it without stopping via a
breakpoint.
Any ideas?
Tom