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

i gotta userform with some text boxes. the people that will be usin
this userform are not computer literate. is it possible to put text i
the textbox like "type here" but make the text go away when it'
clicked? i've tried a few things like
textbox1.value = "type here"
private sub textbox1_click
textbox1.value = ""

no soup.
what else should i try?
thanks MVP's

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,080
Default Disappearing Text in textbox

Try:

Private Sub TextBox1_MouseDown(ByVal Button As Integer, _
ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
TextBox1 = ""
End Sub

--

Vasant


"scottnshelly " wrote in
message ...
i gotta userform with some text boxes. the people that will be using
this userform are not computer literate. is it possible to put text in
the textbox like "type here" but make the text go away when it's
clicked? i've tried a few things like
textbox1.value = "type here"
private sub textbox1_click
textbox1.value = ""

no soup.
what else should i try?
thanks MVP's!


---
Message posted from http://www.ExcelForum.com/



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Disappearing Text in textbox

Thanks,
i knew it would be something along those lines.
Way to go

--
Message posted from http://www.ExcelForum.com

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 195
Default Disappearing Text in textbox

Vasant Nanavati wrote

Private Sub TextBox1_MouseDown(ByVal Button As Integer, _
ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
TextBox1 = ""
End Sub


Is there something similar I can use to detect when a user starts typing an
entry into TextBox1 to make default "<store name" go away?

--
David
  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 195
Default Disappearing Text in textbox

David wrote

Is there something similar I can use to detect when a user starts
typing an entry into TextBox1 to make default "<store name" go away?


Got it worked:

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

--
David
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
How do I stop text from disappearing when I wrap text in Excel? Shavonne Excel Worksheet Functions 0 March 22nd 10 01:38 PM
Disappearing Textbox at the bottom area of a chart Pascal.H Charts and Charting in Excel 0 November 4th 08 04:37 PM
Disappearing text Tim Excel Discussion (Misc queries) 1 June 16th 06 05:02 PM
Text disappearing from cells and comments? tlkcpa Excel Discussion (Misc queries) 1 December 7th 05 08:13 AM
Disappearing Text Boxes [email protected] Charts and Charting in Excel 1 February 5th 05 03:00 AM


All times are GMT +1. The time now is 06:13 PM.

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"