Hi all,
Am trying to write a formula to certain cells but for some reason this ain't working.
Formula is:
cell.FormulaR1C1 = "=if(len((RC[+2])>1);sumproduct((""huuhaa!$H$1:$H$""&lastrow=lajittelu!(RC[-5]))*(""huuhaa!$G$1:$G$""&lastrow=lajittelu!(RC[-6]))*(""huuhaa!$L$1:$L$""&lastrow=lajittelu!(RC[-1]))*(""huuhaa!$O$1:$O$""&lastrow=lajittelu!(RC[+2]))*(""huuhaa!$M$1:$M$""&lastrow));sumproduct((""huuhaa!$H$1:$H$""&lastrow=lajittelu!(RC[-5]))*(""huuhaa!$G$1:$G$""&lastrow=lajittelu!(RC[-6]))*(""huuhaa!$L$1:$L$""&lastrow=lajittelu!(RC[-1]))*(""huuhaa!$M$1:$M$""&lastrow))-sumproduct((""huuhaa!$H$1:$H$""&lastrow=lajittelu!(RC[-5]))*(""huuhaa!$G$1:$G$""&lastrow=lajittelu!(RC[-6]))*(""huuhaa!$L$1:$L$""&lastrow=lajittelu!(RC[-1]))*(""huuhaa!$O$1:$O$""&lastrow=lajittelu!(RC[+2]))*(""huuhaa!$M$1:$M$""&lastrow))"
Yes, I know it's a "bit" long one but I don't know any other way to do this....
Edit: Code-tags added
Bookmarks