+ Reply to Thread
Results 1 to 6 of 6

Referencing and transposing entire rows into new worksheets

Hybrid View

  1. #1
    Registered User
    Join Date
    07-26-2017
    Location
    South Dakota
    MS-Off Ver
    2010
    Posts
    8

    Referencing and transposing entire rows into new worksheets

    Hello all,
    I've been trying to figure out this problem for some time. I have a workbook, with a worksheet that theoretically would look like this:

    Capture.JPG

    On the other worksheets, I would like each sheet to be for a particular division and list all the rows for that particular division. For example, there would be a sheet for 'Finance' that would automatically search for finance division cells and enter all the data for those rows

    First row: 1, Bob, Finance;
    Second Row: 3, Adam, Finance

    This document would be a fluid document, where names can be removed and changed, and regardless of what names are entered, or how many, the code will still search for the entries listed with the correct division.

    I first assumed I could use VLOOKUP for this, but because there will be repeat values I would not be able to use that since it would only look for the first value in the list and stop there. I found a tutorial that allows me to use the INDEX, SMALL, IF and ROW functions to find the value within a particular cell in the same range, but I'm not sure how to make it give me the whole row and not a corresponding cell within the same one. (https://fiveminutelessons.com/learn-...le-values-list).

    I think I can even figure out how to get rid of null values, but I can't figure out what the basic code would be for pulling information. Any suggestions?

    Thank you

  2. #2
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,554

    Re: Referencing and transposing entire rows into new worksheets

    Attach a sample workbook (not image).

    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.

  3. #3
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,554

    Re: Referencing and transposing entire rows into new worksheets

    Guessing your file ..

    Try

    in your "Finance" Sheet with your "master" data in Sheet1

    =IFERROR(INDEX(Sheet1!$A$2:$Z$1000,SMALL(IF(Sheet1!$C$2:$C$1000="Finance",ROW(Sheet1!$A$2:$Z$1000)-ROW($A$2)+1,""),ROWS($A$2:A2)),COLUMNS($A:A)),"")
    ...confirmed by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. You will know the array is active when you see curly braces { } appear around your formula. If you do not CTRL+SHIFT+ENTER you will get an error or a clearly incorrect answer.

    Copy across and down


    Copy same formula for other sheets, changing "Finance" to "Sales", "Admin" ....

  4. #4
    Registered User
    Join Date
    07-26-2017
    Location
    South Dakota
    MS-Off Ver
    2010
    Posts
    8

    Re: Referencing and transposing entire rows into new worksheets

    John,
    I uploaded a practice workbook, and I hope it works for what you requested.

    I also tried the formula provided and using the "Finance" code I only pull out one entry for a Sales division.

    I appreciate your help!
    Attached Files Attached Files
    Last edited by sdr3rpa; 07-26-2017 at 04:31 PM.

  5. #5
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,554

    Re: Referencing and transposing entire rows into new worksheets

    See attached.
    Attached Files Attached Files

  6. #6
    Registered User
    Join Date
    07-26-2017
    Location
    South Dakota
    MS-Off Ver
    2010
    Posts
    8

    Re: Referencing and transposing entire rows into new worksheets

    John, that worked perfect after changing it over to my application!

    Thanks a million!

+ 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. Transposing data conditionally in an entire column
    By encid in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-18-2017, 09:17 AM
  2. Linking Data from 2 worksheets without transposing
    By ahc0037 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-20-2013, 03:00 PM
  3. referencing rows of data from external worksheets
    By apatel615 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 11-15-2012, 11:05 AM
  4. Copy entire Rows to Multiple Worksheets when trigger words appear
    By Phatbassline in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 08-23-2012, 10:10 AM
  5. Transposing across multiple worksheets
    By markvdhouten in forum Excel General
    Replies: 5
    Last Post: 06-28-2012, 06:41 AM
  6. Confused about referencing multiple object code rows in other worksheets?
    By slunk in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-28-2006, 05:40 PM
  7. Transposing an Entire Range of Data into a Single Column
    By ExcelTip in forum Tips and Tutorials
    Replies: 0
    Last Post: 08-28-2005, 11:34 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