We help IT Professionals succeed at work.

Finding selected label from a Tabpage.

crp81
crp81 asked
on
654 Views
Last Modified: 2012-05-10
Could someone help me with this code, I am a beginner C# programmer, I think it will be easy for the experts.

I have a tabcontrol with 5 different tabpages, each tabpage has about six labels. one label in each tab has the forecolor = white (which means it is selected).

If a user selects a new label, I want a method to change the previously selected "White label" in the same tabpage to black.

Detail code please, I am a beginner at C#, Thanks
Comment
Watch Question

Vikram Singh SainiWeb Developer
CERTIFIED EXPERT

Commented:
(1) What you mean by selected label ? Is it mean same when label is clicked (or selected).

(2) Why such requirement?
I can tell the logic as per your comments given

First make all labels colors to Black , then make the selected label to color white.

Web Developer
CERTIFIED EXPERT
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION
Mike TomlinsonHigh School Computer Science, Computer Applications, Digital Design, and Mathematics Teacher
CERTIFIED EXPERT
Top Expert 2009

Commented:
Sounds like you want ONE selection per GROUP...which is a perfect fit for RadioButtons.  Just place them on the TabPages and only one RadioButton per TabPage can be selected at a time.
Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.