Jump to content

Welcome to Geeks to Go - Register now for FREE

Geeks To Go is a helpful hub, where thousands of volunteer geeks quickly serve friendly answers and support. Check out the forums and get free advice from the experts. Register now to gain access to all of our features, it's FREE and only takes one minute. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, post status updates, manage your profile and so much more.

Create Account How it Works
Photo

vb6 gray out text boxes


  • Please log in to reply

#1
TwiztidNinja

TwiztidNinja

    Member

  • Member
  • PipPip
  • 51 posts
i looked on google and cant find it any help?
  • 0

Advertisements


#2
[YF] Daniel

[YF] Daniel

    New Member

  • Member
  • Pip
  • 5 posts
Try "TextBox.Enabled = False"
  • 0

#3
TwiztidNinja

TwiztidNinja

    Member

  • Topic Starter
  • Member
  • PipPip
  • 51 posts
that stops it but how do i make it gray now lol
  • 0

#4
from_herotozero

from_herotozero

    New Member

  • Member
  • Pip
  • 4 posts
what you mean by gray out :tazz:
  • 0

#5
[YF] Daniel

[YF] Daniel

    New Member

  • Member
  • Pip
  • 5 posts

that stops it but how do i make it gray now lol

View Post

No, "TextBox.Enabled = False" grays it.

"TextBox.Locked = True" 'stops' it.
  • 0

#6
FrOzeN

FrOzeN

    New Member

  • Member
  • Pip
  • 6 posts
Text1.Enabled = False
'Greys it out and you can't select it or anything.
---
Text1.Locked = True
'Disables a user from being albe to type/paste text into it.
---
Text1.Backcolor = #8C8C8C
'Will just change the backcolor of the TextBox to grey.
---
Text1.Forecolor = #8C8C8C
'Will just change the color of the text to grey.

Does that cover what your trying to do to the TextBox?
  • 0

#7
TwiztidNinja

TwiztidNinja

    Member

  • Topic Starter
  • Member
  • PipPip
  • 51 posts
yea thanks:-)
  • 0

#8
Ravitv

Ravitv

    New Member

  • Member
  • Pip
  • 1 posts

After what FrOzeN mentioned,

enter

 

Command1.SetFocus

 

in

 

Text1_GotFocus()

 

event to divert the focus pointer inside the textbox to some other Object/Tool like Command button.

Otherwise there will be a cursor blinking inside the textbox that will irritate us.

This works in VB6

 

However

 

Text1.Backcolor = #8C8C8C

Text1.Forecolor = #8C8C8C

 

doesnt work - I dont understand.

 


  • 0

#9
ident

ident

    Member

  • Member
  • PipPipPip
  • 745 posts

Is there any reason why you are using vb6 over VB?


  • 0






Similar Topics

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

As Featured On:

Microsoft Yahoo BBC MSN PC Magazine Washington Post HP