473,385 Members | 1,312 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

InitializeComponent() Procedure

Hi All,

I have been examining the default code for a Windows Form
and had a question about the InitializeComponent()
procedure.

Why is it preceded with
System.Diagnostics.DebuggerStepThrough()?

Is this there as protection, just in case the programmer
tries to alter the code that is already in place?

Thanks,
Mark
Nov 20 '05 #1
3 1350
Cor
Mark,

It skips this code when debugging

I hope this helps?

Cor

Why is it preceded with
System.Diagnostics.DebuggerStepThrough()?

Is this there as protection, just in case the programmer
tries to alter the code that is already in place?

Nov 20 '05 #2
* "Cor" <no*@non.com> scripsit:
It skips this code when debugging


ACK. Nervetheless, I still don't understand why this line is included
in the templates. Some problems in 'InitializeComponent' can be solved
by removing the line and debugging the code.

--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
Nov 20 '05 #3
Cor
Same idea

ACK. Nervetheless, I still don't understand why this line is included
in the templates. Some problems in 'InitializeComponent' can be solved
by removing the line and debugging the code.

Nov 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Ryan Liu | last post by:
I think there are two way to define user control. For example, I want to define a ComoBox with contains only AM, PM items. a.. One way I define a class extends...
1
by: Fulcrum | last post by:
My program has 4 tabs with a few usercontrols that each have a lot of controls on them. Added to that a few oleDb database connections etc. Because of this the program spends a lot of time during...
3
by: Tabo | last post by:
when i build the project using C#, the code in InitializeComponent lost sometimes. Is it a bug?? if yes, can some method fix it? thanks for help. Tabo
8
by: edster | last post by:
A *lot* of our teams code is being deleted from the InitializeComponent() section of a winform, such as Grid settings, event handler hooks, layout settings etc. This mainly seems to happen to 3rd...
0
by: Ryan Liu | last post by:
I have a user control, it must set a property when it is just created, so I set it in its constructor, which has an parameter to specify the property . For example: public class ExecQuest :...
2
by: Craig | last post by:
Is there any side effects to skipping InitializeComponent() and calling a custom method instead? I actually layed out the form, copied the InitializeComponent() method and put it in layout1()...
3
by: David Cho | last post by:
I've noticed that my code in InitializeComponent where I am linking event handlers to events vanishes from time to time. One of the things that triggers the disappearance is when I do something...
3
by: Scott Kilbourn | last post by:
Hi, I added some custom code to the InitalizeComponent function of a control that I'm working on. Every once in a while, I've noticed that the code that I added disappears. I finally tracked...
2
by: Mark Jackson | last post by:
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: ...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.