Solved

textbox setfocus and back color change

Posted on 2008-10-09
3
679 Views
Last Modified: 2012-05-05
Can anyone tell me how to set the setfocus to texbox and change the backcolor with my C# window application?

0
Comment
Question by:tommychiu
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 22

Expert Comment

by:p_davis
ID: 22681554
               TextBox t = new TextBox();
            t.Focus();
                t.BackColor = Color.Blue;
0
 

Author Comment

by:tommychiu
ID: 22681986
actually I have couple of textbox, If I select the first textbox then the back color change to blue otherwise change it back to normal.
0
 
LVL 22

Accepted Solution

by:
p_davis earned 500 total points
ID: 22682010
ok, if you select a text box then you have an enter event for each one or they can all share the same and in that you can set the backcolor as i have shown above.
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article series is supposed to shed some light on the use of IDisposable and objects that inherit from it. In essence, a more apt title for this article would be: using (IDisposable) {}. I’m just not sure how many people would ge…
Introduction Hi all and welcome to my first article on Experts Exchange. A while ago, someone asked me if i could do some tutorials on object oriented programming. I decided to do them on C#. Now you may ask me, why's that? Well, one of the re…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…

626 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question