Excel Calculations from Access

voskouee

Registered User.
Local time
Today, 05:47
Joined
Jan 23, 2007
Messages
96
i have several sheets and i do the following

1. i go to the last cell
2. then move 3 cells on the left
3. i want to do a SUM function there..

any ideas.. this is what i have so far...

ActiveCell.SpecialCells(xlLastCell).Select
ActiveCell.Offset(rowOffset:=3, columnOffset:=-3).Activate
r = ActiveCell.Activate
ActiveCell.FormulaR1C1 = "=SUM(Q1:Q " & r - 1 & ")"



the problem is that i can set the Sum from this field to this field... of the function.. any ideas?

i cant cheat the code from excel since this is not a static cell. each time i have to find the location and do sum

thanks in advance...
 

Users who are viewing this thread

Back
Top Bottom