D
Danny Ni
Hi,
Is there a way to initialize an user control after it's loaded? I know this
is a strange question, so allow me to elaborate, I have an user control
which allow users to enter customer data and save them into SQL server. The
user control has about 50 textboxes and other web controls. To simplify,
let's say user control contains a textbox txtCompany and another textbox
called txtContact, for the first company, I entered "ABC plumbing" into
txtCompany , "Joe Smith" into txtContact. Then I tried to enter second
company, "ABC plumbing" and "Joe Smith" remain in the textboxes, I know
this is the way it is. Question is, is there a way to initialize the user
control after the first company is saved?
I know I can use codes to set txtCompany and txtContact to "", that's not
what I want. Cause I have over 100 user controls of this kind and each of
them has an average of 30-70 web controls, it's a lot of works to write an
initialize routine for every control.
TIA
Is there a way to initialize an user control after it's loaded? I know this
is a strange question, so allow me to elaborate, I have an user control
which allow users to enter customer data and save them into SQL server. The
user control has about 50 textboxes and other web controls. To simplify,
let's say user control contains a textbox txtCompany and another textbox
called txtContact, for the first company, I entered "ABC plumbing" into
txtCompany , "Joe Smith" into txtContact. Then I tried to enter second
company, "ABC plumbing" and "Joe Smith" remain in the textboxes, I know
this is the way it is. Question is, is there a way to initialize the user
control after the first company is saved?
I know I can use codes to set txtCompany and txtContact to "", that's not
what I want. Cause I have over 100 user controls of this kind and each of
them has an average of 30-70 web controls, it's a lot of works to write an
initialize routine for every control.
TIA