I've spent the last five months working on a project full time. I'm currently using VS.NET 2003, and the entire project is in C#.
I'm not going to deny there are benefits to using my IDE. Control placement becomes extremely easy with the GUI, as does hooking events. Basically it's great for giving you a preview of what your forms will look like and easily browsing the structure and layout of your project. However, I find myself restricted by my IDE sometimes. Events, methods, and properties that are marked protected or internal do not show up in my IDE. There are many occasions when I don't want to make these public, but my forms and controls become non-IDE friendly if I don't. Many other problems arise, and I find myself abandoning good programming practices just to make my IDE happy.
For example, today I spent 20 minutes trying to get a form that was inherited from a template to actually display in the designer. It kept coming up with a red X saying "object reference not set to an instance" or something to that effect. I finally fixed the problem with the introduction of several "if (this.DesignMode)" statements. I started thinking about how the IDE was dictating the structure of my program; much of my code could be much cleaner and faster if I didn't have to worry about pleasing the IDE.
Another example is how I've been trying to make a custom control communicate with it's parent control. My goal has been designing the custom control to be completely configurable in the IDE. Working with custom designers and UIs has done nothing but create more headaches and add more potential problems to an already complex program.
I guess I'm wondering if the amount of time spent making controls and forms "play nice with the designer" is really justified? In the case of a program that involves hundreds or thousands of forms, I could see the benefits of spending countless hours making these controls interact perfectly with their containers. However, IMO most projects won't exceed 50 forms. The argument might be made that this program will be modified in the future, so these controls will be reused. What are the chances you're going to continually improve and add functionality to your program without the need to redesign your controls? For each new generation of controls you will again have to use valuable time creating new designers and interfaces.
Anyway, I'm considering the use of the IDE to only lay out the forms and controls, and doing the internals the old fashioned way: by coding! I was wondering if anyone else has any input on the subject. Thanks!
I'm not going to deny there are benefits to using my IDE. Control placement becomes extremely easy with the GUI, as does hooking events. Basically it's great for giving you a preview of what your forms will look like and easily browsing the structure and layout of your project. However, I find myself restricted by my IDE sometimes. Events, methods, and properties that are marked protected or internal do not show up in my IDE. There are many occasions when I don't want to make these public, but my forms and controls become non-IDE friendly if I don't. Many other problems arise, and I find myself abandoning good programming practices just to make my IDE happy.
For example, today I spent 20 minutes trying to get a form that was inherited from a template to actually display in the designer. It kept coming up with a red X saying "object reference not set to an instance" or something to that effect. I finally fixed the problem with the introduction of several "if (this.DesignMode)" statements. I started thinking about how the IDE was dictating the structure of my program; much of my code could be much cleaner and faster if I didn't have to worry about pleasing the IDE.
Another example is how I've been trying to make a custom control communicate with it's parent control. My goal has been designing the custom control to be completely configurable in the IDE. Working with custom designers and UIs has done nothing but create more headaches and add more potential problems to an already complex program.
I guess I'm wondering if the amount of time spent making controls and forms "play nice with the designer" is really justified? In the case of a program that involves hundreds or thousands of forms, I could see the benefits of spending countless hours making these controls interact perfectly with their containers. However, IMO most projects won't exceed 50 forms. The argument might be made that this program will be modified in the future, so these controls will be reused. What are the chances you're going to continually improve and add functionality to your program without the need to redesign your controls? For each new generation of controls you will again have to use valuable time creating new designers and interfaces.
Anyway, I'm considering the use of the IDE to only lay out the forms and controls, and doing the internals the old fashioned way: by coding! I was wondering if anyone else has any input on the subject. Thanks!