Jump to content

Welcome to Geeks to Go - Register now for FREE

Need help with your computer or device? Want to learn new tech skills? You're in the right place!
Geeks to Go is a friendly community of tech experts who can solve any problem you have. Just create a free account and post your question. Our volunteers will reply quickly and guide you through the steps. Don't let tech troubles stop you. Join Geeks to Go now and get the support you need!

How it Works Create Account
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