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 headway123
Posts
#35616
Olá a todos,

Por gentileza, estou com um problema e gostaria de pedir a ajuda de voces.

Estou com o seguinte problema em um formulário do VBA

Ao preencher com a data, o Excel inverte o DIA, pelo MÊS, em qualquer data anterior ao dia 12.

Já mudei a formatação de data do Excel para Portugues, Ingles, e também não deu certo.

Segue os dois códigos que utilizo.

If Len(TxtProximoContato.Text) = 2 Then
TxtProximoContato = TxtProximoContato + "/"
End If

If Len(TxtProximoContato.Text) = 5 Then
TxtProximoContato = TxtProximoContato + "/"
End If



TxtProximoContato.MaxLength = 11 '10/10/2014
Select Case KeyAscii
Case 8 'Aceita o BACK SPACE
Case 13: SendKeys "{TAB}" 'Emula o TAB
Case 48 To 57
If TxtProximoContato.SelStart = 2 Then TxtProximoContato.SelText = "/"
If TxtProximoContato.SelStart = 5 Then TxtProximoContato.SelText = "/"
Case Else: KeyAscii = 0 'Ignora os outros caracteres
End Select

Tenho outro TextBox 'Date' que registra a data atual para cadastro, que as vezes também ocorre essa inversão.

Tentei de várias formas e não consegui resolver.




Desde já agradeço pela atenção!
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