RhythmAddict112
Programmer
Hi all,
Real quick question. I have a page/class named Default.aspx...I've also got a base class called Report, and various reportTypes that inherit from it - one of which is "Department. My question is the following... When I instantiate the Department type within the Default page/class....Is it more efficient to use a constructor that passes the entire Default class, thus providing me with access to various drop down lists and other controls on the page, or is it better to actualyl pass the values of each drop down list/control on the default page into the constructor...Ie
Method 1
Deparment Dpt = new Department(this); //pass class entirely
Method 2
Deparment Dpt = new Department(string ddlOne.selectedValue, string ddlTwo.selectedValue, etc...); //pass string params
Thanks in advance!
Real quick question. I have a page/class named Default.aspx...I've also got a base class called Report, and various reportTypes that inherit from it - one of which is "Department. My question is the following... When I instantiate the Department type within the Default page/class....Is it more efficient to use a constructor that passes the entire Default class, thus providing me with access to various drop down lists and other controls on the page, or is it better to actualyl pass the values of each drop down list/control on the default page into the constructor...Ie
Method 1
Deparment Dpt = new Department(this); //pass class entirely
Method 2
Deparment Dpt = new Department(string ddlOne.selectedValue, string ddlTwo.selectedValue, etc...); //pass string params
Thanks in advance!