Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27
Default Highlighting text in a textbox

Could someone please tell me how to highlight the text in
a textbox on a form?

My textbox has just the number 1 in it, and when the form
is initialized, I'd like the focus on that textbox, with
the number 1 highlighted.

Thank you very much

Daniel

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 29
Default Highlighting text in a textbox

Check out OLHelp for Seltext. SelLength, etc

--
HTH
Roger
Shaftesbury (UK)



"Daniel Bonallack" wrote in message
...
Could someone please tell me how to highlight the text in
a textbox on a form?

My textbox has just the number 1 in it, and when the form
is initialized, I'd like the focus on that textbox, with
the number 1 highlighted.

Thank you very much

Daniel



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Highlighting text in a textbox

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

-Brad

-----Original Message-----
Could someone please tell me how to highlight the text in
a textbox on a form?

My textbox has just the number 1 in it, and when the form
is initialized, I'd like the focus on that textbox, with
the number 1 highlighted.

Thank you very much

Daniel

.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27
Default Highlighting text in a textbox

Thank you

-----Original Message-----
Private Sub UserForm_Initialize()
TextBox1.SelStart = 0
TextBox1.SelLength = Len(TextBox1.Text)
End Sub

-Brad

-----Original Message-----
Could someone please tell me how to highlight the text

in
a textbox on a form?

My textbox has just the number 1 in it, and when the

form
is initialized, I'd like the focus on that textbox, with
the number 1 highlighted.

Thank you very much

Daniel

.

.

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
highlighting text ganga Excel Discussion (Misc queries) 3 June 28th 09 07:30 PM
highlighting text ganga Excel Discussion (Misc queries) 3 June 26th 09 05:51 PM
Highlighting Textbox Garry Jones Excel Programming 1 October 9th 03 06:36 PM
Highlighting or Selecting TextBox entry Gus Gazepis Excel Programming 3 September 8th 03 12:01 AM
check variable(text) with cell (text), textbox Mark[_17_] Excel Programming 1 August 27th 03 01:15 PM


All times are GMT +1. The time now is 11:34 PM.

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

About Us

"It's about Microsoft Excel"