W
Woody Splawn
I don't mean to be too wordy but if you will indulge me a moment I need to
get something clear in my mind. I am concerned about the size of my forms.
I am concerned that if I put too much code in them they may run slow. These
are winforms, nothing to do with the net. In the enviroment I came from
(PowerBuilder) if your form got too big because of code, you just shuffled
off some of it into what VS thinks of as a module. I will do the same in VS
if need be but on the other hand, I don't want to create needless work for
myself. For example.
I just devised some code for a form that allows me to lookup information
using a slide out and a TreeView. The code really helps the navigational
issues for this form but, after all the code was written for
AfterSelectEvent, sub routines to find what node you are on, DoubleClick
events, fill this or that events etc. etc., it took up three pages (when
printed). I know already that this particular form is going to be big when
I add additional functionality because it is going to contain numerous tabs
and 1:m tables with a lot of error checking etc.
With the code I just mentioned, I could probably shuffle off about half or
maybe even two thirds of the code into a module. If this will help my
design I will do it but of course it takes more time, especially when you
have to pass various "sender" and "e" arguments etc. The thought occurs to
me that maybe VS doesn't think like my old tool in this respect. Maybe the
size of the form (in terms of the amount of code it contains) is not as big
a deal.
I don't know if I have explained myself well enough for someone to give a
general opinion but if someone would take a stab at it I would appreciate
it. How concerned should I be about form size and passing off code to a
module? This particular form is already at about 260 KB when you look at it
in Windows Explorer and contains about 3500 lines of code when you include
all the Windows form Designer generated code.
get something clear in my mind. I am concerned about the size of my forms.
I am concerned that if I put too much code in them they may run slow. These
are winforms, nothing to do with the net. In the enviroment I came from
(PowerBuilder) if your form got too big because of code, you just shuffled
off some of it into what VS thinks of as a module. I will do the same in VS
if need be but on the other hand, I don't want to create needless work for
myself. For example.
I just devised some code for a form that allows me to lookup information
using a slide out and a TreeView. The code really helps the navigational
issues for this form but, after all the code was written for
AfterSelectEvent, sub routines to find what node you are on, DoubleClick
events, fill this or that events etc. etc., it took up three pages (when
printed). I know already that this particular form is going to be big when
I add additional functionality because it is going to contain numerous tabs
and 1:m tables with a lot of error checking etc.
With the code I just mentioned, I could probably shuffle off about half or
maybe even two thirds of the code into a module. If this will help my
design I will do it but of course it takes more time, especially when you
have to pass various "sender" and "e" arguments etc. The thought occurs to
me that maybe VS doesn't think like my old tool in this respect. Maybe the
size of the form (in terms of the amount of code it contains) is not as big
a deal.
I don't know if I have explained myself well enough for someone to give a
general opinion but if someone would take a stab at it I would appreciate
it. How concerned should I be about form size and passing off code to a
module? This particular form is already at about 260 KB when you look at it
in Windows Explorer and contains about 3500 lines of code when you include
all the Windows form Designer generated code.