Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 37
Default Excel text box properties

I have a text box inserted in my worksheet from the Control Toolbox toolbar.

Is there an option which allows me to specify that existing text in the box
is overwritten by new entries (I have the number of possible characters
restricted so this would be very useful). I can't find one in the Properties
window so maybe the only solution is VBA?

Thanks
--
R Ormerod
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 78
Default Excel text box properties

You can have this code when the text box gets the focus:

Private Sub TextBox1_GotFocus()

TextBox1.SelStart = 0
TextBox1.SelLength = Len(TextBox1.Value)

End Sub

(Replace TextBox1 by the name of your textbox, it appears four times)

--
Message posted via http://www.officekb.com

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
using properties in text formulas [email protected] Excel Discussion (Misc queries) 2 August 29th 06 08:49 PM
Excel Properties Harley New Users to Excel 2 January 19th 06 11:26 PM
How do I set Default import properties such as Text Qualifier? UABCSA Excel Discussion (Misc queries) 0 December 8th 05 05:01 PM
Excel properties - 'archive'? Shedlord Excel Discussion (Misc queries) 0 August 2nd 05 05:09 PM
Converting custom cell properties to text Hnelg Excel Discussion (Misc queries) 2 May 3rd 05 12:20 PM


All times are GMT +1. The time now is 06:26 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"