Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Clear a MaskEDBox that has an input mask in VB 1

Status
Not open for further replies.

BlackSand

Programmer
Jan 20, 2003
4
CA
I'm trying to clear a MaskEDBox that containt text with a simple command: txtCoopZip.Text = ""

But I guess that since I have an input mask that looks like this: >?#? #?#, it gives me an error. I would guess its because it doesn't allow space.

Pls help. thx

BlackSand
 
I found the problem u basicly need to clear it with the input mask... if its set to stars then it would be
txtZipCoop = "*** ***"
 
You should also be able to clear the .ClipText property.

txtCoopZip.ClipText = ""

The .ClipText property ignores the mask.
Thanks and Good Luck!

zemp
 
The .ClipText property thows a "Read-Only Property" error for me. I use the following code:

Code:
txtCoopZip.PromptInclude = False
txtCoopZip.Text = ""

Hope this helps.
tbuch
 
The .ClipText property throws a "Read-Only Property" error for me. I used the following code:

Code:
txtCoopZip.PromptInclude = False
txtCoopZip.Text = ""

Hope this helps.
tbuch
 
You have to clear it using the mask

if your mask is >?#? #?#
then you have to do

textbox.text = ">?#? #?#"

Transcend
[gorgeous]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top