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 GabrielBrito031
#56663
Boa noite Gurus,

Poderiam me ajudar com o código VBA para realizar loop para automatizar o preenchimento da fórmula abaixo.
A fórmula é para informar o resultado da mesma célula de 31 abas (corresponde aos dias) na mesma pasta de trabalho.

Sub Macro1()

Range("C58").Select
ActiveCell.FormulaR1C1 = "='02'!R5C24"
Range("C59").Select
ActiveCell.FormulaR1C1 = "='03'!R5C24"
Range("C60").Select

End Sub
Por osvaldomp
#56671
Experimente:
Código: Selecionar todos
Sub InsereFórmulasV1()
 Range("C58:C88") = "=INDIRECT(""'0""&ROW(A1)&""'!X5"")"
End Sub
ou
Código: Selecionar todos
Sub InsereFórmulasV2()
 Dim k As Long
  For k = 1 To 31
   Cells(k + 57, 3) = "='0" & k & "'!X5"
  Next k
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