TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Tim Camper
NA
10
0
Duplicate panels and controls created at runtime - Which button and textbox is it?
Jan 2 2011 11:28 PM
My application creates panels and controls, ie. labels, textboxes, etc., based on user input. The controls on the panel are located in the same place each time.
I need your help to figure out how in the program to know which textbox named "txtHandi" goes with what panel.
My code falls apart here: void btnPlayerName_Click(object sender, EventArgs e)
It does not recognize the btnPlayerName I click on or the txtHandi. I am sure it is something I am overlooking!
1. Please help me understand how I can associate each of the "btnPlayerName" to the panel it shows up on.
2. and how I can associate each of the txtHandi on that same panel so the line of code "int playerHandicap = Convert.ToInt32(txtHandi.Text);"
in the void btnPlayerName_Click(object sender, EventArgs e) will work.
I suspect I will need help with:
int playerGross = Convert.ToInt32(myGross[i].Text);
int holeHandicap = (handicapofhole[i]);
in "void btnPlayerName_Click(object sender, EventArgs e)" also.
If you can jump start me with a few of these items I most likely will be able to connect the dots.
I am providing portions of code for your review.
Thanks in advance for your help.
Reply
Answers (
5
)
AntiAlias the whole image
How to read and write data from excel sheet using c# .net?