Sub InitializeComponent()

  • Thread starter Thread starter Mark Jackson
  • Start date Start date
M

Mark Jackson

Hi,

I have been examining the default code for a typical
windows form. Everything seems to make sense. However,
the InitializeComponent() subroutine is proceeded with the
following syntax:

System.Diagnostics.DebuggerStepThrough()

What is the purpose of this code? Does this mean that the
VB compiler will double-check to make sure nobody has
altered the code within this procedure?

Thanks,
Mark
 
Mark,
What is the purpose of this code? Does this mean that the
VB compiler will double-check to make sure nobody has
altered the code within this procedure?

No, it means that when you're stepping through your code in the
debugger it will not step into InitializeComponent().



Mattias
 
* Mattias Sjögren said:
No, it means that when you're stepping through your code in the
debugger it will not step into InitializeComponent().

Often people have problems with their 'InitializeComponent' sub. Why
do the templates include this attribute?
 
Back
Top