By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,217 Members | 1,443 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,217 IT Pros & Developers. It's quick & easy.

Calling Methods in User Controls

P: n/a

I've a questionnaire application where each question is a separate User
Control that gets loaded dynamically at run-time. Each question has a
list of answer options stored in a database. I need to load the
options when the question loads and save the answer selected when the
users clicks "Save".

I've found I can load the answer options with a "LoadOptions();" in the
Page_Load for each of the User Control.

What's the best way to save the answers? I can put a "SaveAnswer();"
method in each User Control, but how do I iterate through all the
loaded User Controls to call this method from the Save button on the
parent form?

I hope the answer is as pleasing and enlightening as others have been.


John South

May 11 '06 #1
Share this Question
Share on Google+
1 Reply

P: n/a
Just to let anyone know. I solved this by creating a public static
variable in global.asax.cs to the store the value so I can get to it

John South

May 20 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.