+ Reply to Thread
Results 1 to 5 of 5

Is it possible to Cascade Data Tables?

  1. #1
    Registered User
    Join Date
    10-18-2007
    Posts
    28

    Is it possible to Cascade Data Tables?

    I have a complicated sheet with a Data Table, call it DTA.

    DTA has a number of rows for which I calculate an AVERAGE of a particular column.

    There are many cells whose values effect DTA output - not just the one I chose for the DT input.

    Now I want vary one of these other cells and see how it effects AVERAGE.

    So I build DTB with an input of this new varied cell and an output of the varied AVERAGE.

    Now when DTB populates the rows by varying this new varied cell, DTA must recalculate to get the proper AVERAGE for the DTB row.

    That is not happening.

    QUESTION: Can you define a DTB where for each row, another DTA must recalculate to populate?

    OR: Is it possible to Cascade Data Tables?

  2. #2
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,879

    Re: Is it possible to Cascade Data Tables?

    You can prepare a macro, which varies the input cell and copies the averages obtained for each value into dtb sheet.
    Best Regards,

    Kaper

  3. #3
    Registered User
    Join Date
    10-18-2007
    Posts
    28

    Re: Is it possible to Cascade Data Tables?

    I've never written a macro which interacts with the sheet - mine have an input from the sheet, do their thing, then place an output on the sheet.

    If I write to a cell, does the sheet recalculate before the next MACRO statement is processed? (This would be necessary since I need the recalculated cells to copy to the new table I'm building.)

    ALSO, I'm trying to think of any tricks that still might allow Table B to use Table A results.

  4. #4
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,879

    Re: Is it possible to Cascade Data Tables?

    See attached model file and use similar approach.

    The macro behind is easy one:
    Please Login or Register  to view this content.
    It takes input data from each row of DTB (starting row 2 ending last row with data in column B: Cells(Rows.Count, "B").End(xlUp).Row)
    Copies it into "input row" of sheet DTA.
    Enforces recalculation od the workbook.
    And copies final result from cell G15 in DTA into DTB column A and the same row as input data was.
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    10-18-2007
    Posts
    28

    Re: Is it possible to Cascade Data Tables?

    THANKS for the code. It was the Application.Calculate that I was unaware of but suspected one existed.

    Would set up MACRO to run on OPEN and also upon any RECALCULATION.

    I know how to do on OPEN, but how to run on RECALC?

+ 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] Combobox cascade + Textbox
    By Nuno Neves in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 03-23-2014, 12:29 PM
  2. [SOLVED] Need to cascade a formula every 24 lines
    By johndoby in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 08-13-2013, 01:39 PM
  3. Validation in cascade...
    By Jehan in forum Excel General
    Replies: 2
    Last Post: 06-19-2007, 08:47 AM
  4. cascade combo in subform
    By Richard in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 12-11-2005, 05:55 PM
  5. Cascade Validation
    By matelot in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-17-2005, 10:20 PM

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