Este fórum está sendo desativado

Depois de 9 anos, este fórum será desativado. Mas calma.... estamos migrando para uma comunidade no DISCORD. Junte-se a nós.

ENTRAR PARA DISCORD

Tópicos relacionados a códigos VBA, gravação de macros, etc.
  • Avatar do usuário
Por Super385011
Posts
#21545
Como faço para trocar a cor das letras em uma textbox.

gostaria que a textbox1 as letras ficasse azul, a textbox 2 ficasse vermelha e a textbox 3 com a condição que se a texbox 1 for maior que a textbox2 fique azul caso contrario fique vermelha.

estou puxando os valores de uma planilha automaticamente

linha a = textbox1 azul
linha b = textbox2 vermelho
linha c = textbox3 condição a>b =azul b>a = vermelho
Avatar do usuário
Por alexandrevba
Avatar
#21546
Bom dia!!

Até onde eu me lembre só você consegue mudar o fundo do textbox.
Código: Selecionar todos
Private Sub TextBox1_Change()
    Me.TextBox1.BackColor = RGB(135, 206, 250)
End Sub
Código: Selecionar todos
Private Sub TextBox2_Change()
    Me.TextBox2.BackColor = RGB(255, 0, 0)
End Sub
Código: Selecionar todos
Private Sub TextBox3_Exit(ByVal Cancel As MSForms.ReturnBoolean)
    If (TextBox1.Value) > (TextBox2.Value) Then Me.TextBox3.BackColor = RGB(135, 206, 250)

    If (TextBox2.Value) > (TextBox1.Value) Then Me.TextBox3.BackColor = RGB(255, 0, 0)

End Sub
Att
Por babdallas
#21565
Veja se é isso.
Você não está autorizado a ver ou baixar esse anexo.
long long title how many chars? lets see 123 ok more? yes 60

We have created lots of YouTube videos just so you can achieve [...]

Another post test yes yes yes or no, maybe ni? :-/

The best flat phpBB theme around. Period. Fine craftmanship and [...]

Do you need a super MOD? Well here it is. chew on this

All you need is right here. Content tag, SEO, listing, Pizza and spaghetti [...]

Lasagna on me this time ok? I got plenty of cash

this should be fantastic. but what about links,images, bbcodes etc etc? [...]

Estamos migrando para uma comunidade no Discord