I have a formula (which is an add-in from our accounts package so don't worry that it is not a normal Excel formula) which I want to 'build' either in the cell or in a macro so that the contents of two cells define the formula.
The formula is: =EntAddNomVATLines6(AD17,AD1,AD4,AD2,AD3,AD5,"",AD16,AD6:AD15,B20:B200,H20:H200,1,E20:E200,1,S20:S200,T20:T200,U20:U200,F20:F200,"AAA","","",V20:V200,1,I20:R200)
This basically posts a journal using data in rows 20 to 200 but I want the rows to be user definable so for instance if cells A1 and A2 contain 20 and 25 then the formula will read:
=EntAddNomVATLines6(AD17,AD1,AD4,AD2,AD3,AD5,"",AD16,AD6:AD15,B20:B25,H20:H25,1,E20:E25,1,S20:S25,T20:T25,U20:U25,F20:F25,"AAA","","",V20:V25,1,I20:R25)
I could probably use Indirect but I think the formula would be huge so I was wondering if I could build the formula in the cell using a macro?
I would also like to highlight the rows currently defined by A1 and A2 so that it is clear to the user which rows will be used.
Any thoughts?
Bookmarks