View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.newusers
mikeg710 mikeg710 is offline
external usenet poster
 
Posts: 8
Default Enable Command Button After Entering Text

I am a beginner with Excel VBA programming and would greatly appreciate any
advice on how to accomplish the following.

I created a user form with three text boxes (txtName, txtDescription,
txtProcess) and two command buttons (cmdAdd, cmdCancel). I do not want the
cmdAdd button enabled until a user enters valid text into both the txtName
AND txtDescription text boxes. I have the Enabled property for the cmdAdd
button set to False.

How and where do I code the procedure to set the cmdAdd control's Enabled
property to True as soon as the user has entered valid text in BOTH the
txtName and txtDescription controls?

Thank you in advance for any help on this question!