+ Reply to Thread
Results 1 to 2 of 2

Use of Dynamic Formula to Consolidate two Tabs where Data Validation is done twice

  1. #1
    Registered User
    Join Date
    05-15-2014
    MS-Off Ver
    Excel 2003
    Posts
    2

    Use of Dynamic Formula to Consolidate two Tabs where Data Validation is done twice

    Hi ,

    am trying to consolidate in Consol Tab , sum of two cities data for each of P&L Line items ( all rows Basically ) with two data validation :
    1. IF the figures are in USD , it should basically divide City 3 Data by exchange rate in Cell B3 of Consol Tab and add tabs City 1 Forecast & City 3 Forecast

    2 Also , the second data validation is If year is changed in Cell E1 , then it it should total for 12 months of that year only from two tabs City 1 Forecast and City 3 Forecast .
    Am trying to use offset function along with IF and SUM Function across the Consol tab to data validation work but this is not working.
    Kindly help at urgent level
    Attached Files Attached Files

  2. #2
    Valued Forum Contributor
    Join Date
    01-16-2012
    Location
    England
    MS-Off Ver
    MS 365
    Posts
    1,393

    Re: Use of Dynamic Formula to Consolidate two Tabs where Data Validation is done twice

    raghav,

    Think the attached does what you want.

    There was no "Exchange Rate" in B3 of the Consol tab, so I added one.

    I added a Year DropList in H4 of the Consol tab, which sets the months in Row 4, enabling the formula to find the relevant columns in the two Forecasting sheets.

    Code in B6 of the Consol sheet works as follows:

    In row 6 of the Consol sheet ("BlackCar"), it puts into each Column the values in the matching cell in the City 1 Forecasting sheets, and adds the values in the matching cell in the City 3 Forecasting sheets

    If both the Consol and City Forecast use the same currency, the numbers are copied "as is".

    If either Forecast sheet uses a different currency to your choice in the Consol sheet, the value copied across is set by the Consol sheet.
    If the Consul is set for Dollars, and the Forecast is in Euros, it multiples the Forecast by the Exchange rate (1 Euro = $1.14)
    If the Consol is set for Euros, and the Forecast is in Dollars, it divides the Forecast by the Exchange rate ($1 = $0.87)

    Copy the Code across all twelve columns, and down each row, adjusting the references appropriately.

    You can test it by (a) changing the currency on any of the sheets to see the effect, (b) change the Exchange Rate, and (c) Select a different Year in H1.

    =IF(B1='City1 Forecast'!$D$1,INDEX('City1 Forecast'!$B5:$AJ5,MATCH(B$4,'City1 Forecast'!$B$3:$AK$3)),IF(B1="USD",INDEX('City1 Forecast'!$B$5:$AJ$5,MATCH(B$4,'City1 Forecast'!$B$3:$AK$3)*($B$2)),INDEX('City1 Forecast'!$B$5:$AJ$5,MATCH($B$4,'City1 Forecast'!$B$3:$AK$3)/$B$2)))+IF($B$1='City 3 Forecast'!$C$1,INDEX('City 3 Forecast'!$B$5:$AN$5,MATCH(B$4,'City 3 Forecast'!$B$3:$AN$3)),IF(B1="USD",INDEX('City 3 Forecast'!$B$5:$AN$5,MATCH(B$4,'City 3 Forecast'!$B$3:$AN$3)*$B$2),INDEX('City 3 Forecast'!$B$5:$AN$5,MATCH($B$4,'City 3 Forecast'!$B$3:$AN$3)*$B$2)))

    (if the currency in D1 of City 1 Forecast matches the currency in B1 on the Consol, find in Forecast row 5 the column matching the date in B4.
    If the currencies differ, multiply or divide the value by the exchange rate.
    Add the same calculation for the City 3 Forecast)

    Ochimus
    Attached Files Attached Files
    Last edited by Ochimus; 04-30-2016 at 09:36 AM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] To consolidate selected data from other tabs
    By akhileshgs in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 01-21-2015, 08:24 AM
  2. [SOLVED] Loop through tabs in a workbook to consolidate data
    By amartin575 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-09-2013, 11:23 AM
  3. [SOLVED] Formula that references different tabs according to a data validation field?
    By Rizzu in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 12-27-2012, 06:27 PM
  4. Multiple tabs with dynamic data condensed by formula to one tab
    By mhgleitz in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-18-2012, 09:30 PM
  5. Problem with Formula based on Data Validation Selection from multiple tabs
    By warrior2411 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-13-2012, 05:32 PM
  6. VB Code to Consolidate data from different files / tabs
    By tt388 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-29-2011, 11:53 AM
  7. [SOLVED] Indirect formula using Data Validation List of Worksheet Tabs
    By Scott in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 12-05-2005, 11:10 AM

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1