Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 68
Default Highlighting Textbox1 Value when form initializes.

I have a userform and would like on userform initialization to highlight the
text in textbox1. What would the code be for this?


Thanx

Todd Huttenstine



  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 95
Default Highlighting Textbox1 Value when form initializes.

Todd,

Use code like the following:

Private Sub UserForm_Initialize()
With Me.TextBox1
.SelStart = 0
.SelLength = Len(.Text)
End With
End Sub

--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com

"Todd Huttenstine" wrote in message
...
I have a userform and would like on userform initialization to highlight

the
text in textbox1. What would the code be for this?


Thanx

Todd Huttenstine





  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 68
Default Highlighting Textbox1 Value when form initializes.

thanx
"Chip Pearson" wrote in message
...
Todd,

Use code like the following:

Private Sub UserForm_Initialize()
With Me.TextBox1
.SelStart = 0
.SelLength = Len(.Text)
End With
End Sub

--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com

"Todd Huttenstine" wrote in message
...
I have a userform and would like on userform initialization to highlight

the
text in textbox1. What would the code be for this?


Thanx

Todd Huttenstine







Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can a form made in Excel 2002 be converted into a fillable form? Paraclete Excel Discussion (Misc queries) 1 February 20th 07 09:20 PM
TextBox1 to Label4 damorrison Excel Discussion (Misc queries) 5 March 12th 06 04:05 PM
how can I make a form number change everytime the form is opened babydumplingspita Excel Worksheet Functions 1 October 10th 05 07:58 PM
Highlighting blanks via GO TO SPECIAL is not highlighting blank cells - HELP, I'm totally stuck. Jamie Furlong Excel Discussion (Misc queries) 6 August 28th 05 09:27 PM
UserForm1.Textbox1.SetFocus Question Zane Greer Excel Programming 1 September 14th 03 11:59 AM


All times are GMT +1. The time now is 10:57 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"