Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
summing cells
Hi Group,
Sorry for a probably simpel question. What code to use for adding the values of cells A1 to N1 in VBA, without using the FormulaR1C1 method? Brgds CG Rosén |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
summing cells
Result = Range("A1").Value + Range("N1").Value or if putting into cell on worksheet eg C2 Range("C2").Formula = "=A1 + N1" Cheers Nigel "CG Rosén" wrote in message ... Hi Group, Sorry for a probably simpel question. What code to use for adding the values of cells A1 to N1 in VBA, without using the FormulaR1C1 method? Brgds CG Rosén |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
summing cells
MsgBox Application.Sum(Range("a1:n1"))
-- Don Guillett SalesAid Software "CG Rosén" wrote in message ... Hi Group, Sorry for a probably simpel question. What code to use for adding the values of cells A1 to N1 in VBA, without using the FormulaR1C1 method? Brgds CG Rosén |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
summing cells
Hi,
To sum a1:n1 of the active sheet: Dim v as Variant v = application.WorksheetFunction.Sum(range("A1:N1")) Then you can place it in another cell: Range("A2") = v Regards, Sebastienm "CG Rosén" wrote: Hi Group, Sorry for a probably simpel question. What code to use for adding the values of cells A1 to N1 in VBA, without using the FormulaR1C1 method? Brgds CG Rosén |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Summing 2 columns cells into a 3rd colums cells | Excel Discussion (Misc queries) | |||
not summing all the cells | Excel Discussion (Misc queries) | |||
Summing Cells with #N/A | Excel Worksheet Functions | |||
Summing of Two cells does not sum!! | Excel Discussion (Misc queries) | |||
Finding cells and summing variable cells | Excel Programming |