+ Reply to Thread
Results 1 to 2 of 2

Populate and rezise table2 as table1 changes

  1. #1
    Registered User
    Join Date
    06-05-2017
    Location
    Oslo, Norway
    MS-Off Ver
    Office365/2016
    Posts
    14

    Populate and rezise table2 as table1 changes

    Structure:
    I have two tables, table1, "Kontoinformasjon" in sheet1 and table2, "Utestående_Betaling" in sheet2.
    Table1 contains a list of acount numbers in one column and the owner of that account number in a second column. This list is not fixed in
    Sheet1 in which the table2 is located also has a cell with a drop down list of owners.

    Functions:
    Table2 should be populated with account numbers of the choosen owner, and rezise it self accordingly.

    So far:
    I am using a function to populate table1 from table2. This list all the account regardless of the owner.
    Please Login or Register  to view this content.
    Now I need to manually add rows to table2 until alle accounts are listed, whcih is cumbersome.

    I would like to rezise the table2 to match the number of rows needed, but so far I am stuck on retrieving the numbers of rows from table1, as the code throws an Index Out of Bounds error. This is the code:
    Please Login or Register  to view this content.
    When this code works, I will:
    1. Rewrite the function to only retrieve accounts by the choosen owner
    2. Only count rows with a specific owner in the code

  2. #2
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,920

    Re: Populate and rezise table2 as table1 changes

    It's difficult to visualize the requirements without looking at the spreadsheet. It would seem that simply appending the information to the second table should make that table resize automatically. I would still take VB code to detect the change and put the value in the proper cell, but the table should take care of resizing itself.

    Attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.
    One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.

    A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.

+ 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] How to convert uploaded table1 to table2?
    By tta.akmal in forum Excel General
    Replies: 5
    Last Post: 04-16-2017, 08:04 AM
  2. If-Then copying specific data from Table1 to Table2 in a specific order
    By b4tmast in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-15-2016, 04:28 AM
  3. [SOLVED] When record is created/deleted in Table1, then add/delete record to Table2
    By michellepace in forum Excel General
    Replies: 1
    Last Post: 11-26-2015, 04:45 AM
  4. [SOLVED] Displaying a column from table2 based on a filter in table1
    By FVMLABOLG in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 11-06-2015, 04:58 PM
  5. Copy TABLE1 ROW from one sheet to TABLE2 LAST ROW in another sheet
    By jigneshwaghela07 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-02-2014, 08:51 AM
  6. Copy TABLE1 ROW from one sheet to TABLE2 LAST ROW in another sheet
    By jigneshwaghela07 in forum Hello..Introduce yourself
    Replies: 0
    Last Post: 06-01-2014, 12:56 PM
  7. How to copy Table2 columns in to Table1 ?
    By bsaimsc in forum Access Programming / VBA / Macros
    Replies: 1
    Last Post: 10-04-2012, 07:13 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