Consulting

Results 1 to 2 of 2

Thread: Array Forumla Help

  1. #1
    VBAX Regular
    Joined
    Jun 2008
    Posts
    16
    Location

    Array Forumla Help

    Hi Guys,

    Hope you can help.

    I've attached a spreadsheet which should hopefully illustrate what I need help with.

    Basically, I have a spreadsheet with values in different currencies. I also have exchange rates for those currencies. (Cells highlighted in blue on spreadsheet).

    What I would like to be able to do is to use a formula to convert the values from their original currency into USD and GBP and then sum the respective values to get the values in the cells highlighted in green.

    Am I able to do this with an array formula or would I be better off using a macro to do the calculation?

    (Also, although the example spreadsheet only has 5 rows, I do not know in advance how many rows the spreadsheet will have, so I need a formula that will work for the whole column).

    Any help appreciated.

  2. #2
    Distinguished Lord of VBAX VBAX Grand Master Bob Phillips's Avatar
    Joined
    Apr 2005
    Posts
    25,453
    Location
    You can't do whole columns, but just use a high number or dynamic ranges

    =SUMPRODUCT(A2:A2000,VLOOKUP("GBP",$D:$E,2,FALSE)/$E2:$E200)

    etc.
    ____________________________________________
    Nihil simul inventum est et perfectum

    Abusus non tollit usum

    Last night I dreamed of a small consolation enjoyed only by the blind: Nobody knows the trouble I've not seen!
    James Thurber

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •