Home |
Search |
Today's Posts |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
ActiveCell.FormulaR1C1 = "=AVERAGE(R[-" & VaraRowNo1 & "]C[-6]:R[" &
VarRowNo2 & "]C[-6])" -- Kind regards, Niek Otten "ditzafar" wrote in message ... Sorry, but I stille didn't understand how I using excel function with variable. For example I want to use the function average. the recorde of this macro looks like this ActiveCell.FormulaR1C1 = "=AVERAGE(R[-6]C[-6]:R[3]C[-6])" I want to replace the index of the row with variable thanks:) Niek Otten Wrote: If you mean a User defined Function (UDF): Function DemoSum(a As Range) As Double DemoSum = a.Count End Function -- Kind regards, Niek Otten "ditzafar" wrote in message ... Could I use excel function when I don't know the range and I need to define it with variable. If it possible, how I do it? Thanks:) -- ditzafar ------------------------------------------------------------------------ ditzafar's Profile: http://www.excelforum.com/member.php...o&userid=29475 View this thread: http://www.excelforum.com/showthread...hreadid=497502 -- ditzafar ------------------------------------------------------------------------ ditzafar's Profile: http://www.excelforum.com/member.php...o&userid=29475 View this thread: http://www.excelforum.com/showthread...hreadid=497502 |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Variable Value Function Help? | Excel Worksheet Functions | |||
How to graph x-variable versus y-variable in Excel ? | New Users to Excel | |||
Using a range variable inside a excel function | Excel Discussion (Misc queries) | |||
why is it saying sheetcnt is "variable not defined" how to do a global variable to share over multiple functions in vba for excel? | Excel Worksheet Functions | |||
Set variable to a function | Excel Programming |