Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Another quick note. Your function can, of course, "modify" (better to say
"put new values" to) a contigues range of cells. This is a way called "array function" €“ find out the Help for it. In your case you would have to use your wit with it, i.e. to place the argument at the end €“ to E1 cell instead of C1, or to create a pair of functions - for the left and right ranges alongside the argument cell. The best way, with the same function algorithm €“ as I take it from your example - is to propagate "one cell" function by copying. When even this is out of your intentions, the only resting method is creating a subroutine. By means of it you can do almost everything; you must resign yourself only to the instant response to the argument change that the function provides. Regards -- Petr Bezucha "rat59man" wrote: I am trying to write a function to modify a group of cells. As an example in cell C1 I insert "=myfunction(1)" and in cells A1, B1, D1, E1 I want the values of 3, 5, 7, and 11 placed. At the assignment I get a 1004 error number returned. My thought is that functions are not allowed to modify cells directly. Is this correct? -- John Rater |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How to modify a range in a function? | Excel Programming | |||
Modify function for another workbook | Excel Programming | |||
Unable to modify cells in a VBA function | Excel Programming | |||
How a function can modify a value from some cells ? | Excel Programming | |||
to modify cells from a function | Excel Programming |