Ich möchte ein Formular von einer Zelle zu einem anderen in der gleichen Zeile mit VBA,VBA/Excel: Möglichkeit, Formel dynamisch zu kopieren
z.
E1 = "=(E441+E747+E750)*-1"
to
F1 -> = "=(F441+F747+F750)*-1"
Aber dieser Code-Schnipsel:
Dim r As Excel.Range
Dim lRow As Long
lRow = tbXlApp.WorksheetFunction.Match("Test", Range("C:C"), 0)
'Line 4
tbXlWs.Cells(lRow, 5).Formula = "=(E441+E747+E750)*-1"
For Each r In tbXlWs.Range(tbXlWs.Cells(lRow, 6), tbXlWs.Cells(lRow, 4 + x))
r.Formula = tbXlWs.Cells(lRow, 5).Formula
Next r
einfach fügt die Formel der Zelle in Zeile 4 definiert
das Beispiel unter Hinweis auf, führt dies in
E1 = "=(E441+E747+E750)*-1"
to
F1 -> = "=(E441+E747+E750)*-1
Aber In diesem Szenario sollte Spalte F sein. Was muss ich ändern?
Danke!
tolle Arbeit, danke! funktioniert perfekt. – mffm