Help!! Colours!! (1 Viewer)

Tracy

Registered User.
Local time
Today, 06:59
Joined
Oct 19, 2001
Messages
71
Can anyone please tell me how to set a colour of a text box on a report in visual basic.

I've tried Me!TextBox = RGB(255,0,0) but it just sets it to a weird number.

I think there is a format function but I can't find it.

Any help would save me!
Thanks
 

Mile-O

Back once again...
Local time
Today, 06:59
Joined
Dec 10, 2002
Messages
11,316
Me!TextBox.BackColor = RGB(255,0,0)
 

Tracy

Registered User.
Local time
Today, 06:59
Joined
Oct 19, 2001
Messages
71
Thanks, this works, but I wanted to change the font color.

Any ideas...husband?
 

Tay

likes garlic
Local time
Today, 06:59
Joined
May 24, 2002
Messages
269
Me!TextBox.ForeColor = RGB(255,0,0) should do it.

HTH
 

Fornatian

Dim Person
Local time
Today, 06:59
Joined
Sep 1, 2000
Messages
1,396
Rather than use the RGB function, you can use one of the VB constants such as vbRED as in:

Me!TextBox.BackColor = vbRed
 

Users who are viewing this thread

Top Bottom