I am trying to write my first code ever in excel VBA for Mac. All I want to do is add two numbers. Sounds Hard, Right? I keep getting this error Compile Error: invalid use of property. Then a debugger window opens with the first line highlighted.
Sub abbas()
'adds two numbers
'from e2 and e3 and puts the result in e4
Sheets("SHEET 1").Select
Range("e2").Select
A = ActiveCell.Value
Range("e3").Select
B = ActiveCell.Value
Range("e4").Select
ActiveCell.Value = A + B
Range ("e5")
End Sub
Aucun commentaire:
Enregistrer un commentaire