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.
Por Diego100ges
Posts
#61485
Pessoal, boa tarde.

Estou tendo um problema em um laço for, que é o seguinte, eu disparo um e-mail através de uma sub com base nos clientes que estavam tickados no check box da listview.
Porém na assinatura do respectivo que fica em outra sub, acontece de pegar as informações da assinatura do ultimo cliente selecionado, e não respectivo cada cliente com os dados do seu gestor na assinatura.

Será que é algo errado com o código?
Código: Selecionar todos
Sub assinatura_email(Assinatura)

For i = 1 To Me.lista_clientes.ListItems.Count

If Me.lista_clientes.ListItems.Item(i).Checked = True Then

Gestor = Me.lista_clientes.ListItems.Item(i).SubItems(6)
EmailGestor = Me.lista_clientes.ListItems.Item(i).SubItems(7)
TelefoneGestor = Me.lista_clientes.ListItems.Item(i).SubItems(8)

Assinatura = "texto"
Assinatura = Assinatura & "texto" & Gestor 
Assinatura = Assinatura & "texto" & Email
Assinatura = Assinatura & "texto" & Telefone

End If

Next i

End Sub
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