+ Reply to Thread
Results 1 to 3 of 3

formula which returns horizantal range to vertical range

  1. #1
    Registered User
    Join Date
    04-02-2010
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    13

    Question formula which returns horizantal range to vertical range

    i have a workbook consisting of 10 work sheets. In sheet 9 the first column contain some data and horizontally 10 columns contain the data in connection with first column.

    I want in sheet 1, if i give data of first column of sheet 9, i should get the horizontal data of that first column in sheet 9 into vertical in the sheet 1 i.e. i need the formula which returns the horizontal range of cells as vertical range.

    regards,
    unas.

  2. #2
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: formula which returns horizantal range to vertical range

    You would use something like:

    Sheet1!A2:
    =INDEX(Sheet9!$1:$1000,MATCH($A$1,Sheet!9!$A:$A,0),ROWS(A$2:A2))
    copied down
    (adjust range as necessary)

    where Sheet1!A1 holds the criteria as found in Col A on Sheet9.

    I would add though that

    a) it makes sense to calculate the MATCH separately and refer to the cell containing the result in the INDEX calls (ie conduct once only)

    b) if the number of columns to return varies then conduct an appropriate test to determine how many values are to be returned and use that value via a pre-emptive IF to est. as to whether or not you need calculate the INDEX for a given row.

  3. #3
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: formula which returns horizantal range to vertical range

    If your data in Sheet9 is in A1:K20, then perhaps

    =INDEX(Sheet9!$A$1:$K$20,MATCH($A$1,Sheet9!$A$1:$A$20,0),ROW()-ROW($A$1)+1)

    where $A$1 is the column header to match to row header in Sheet9

    copied down after adjusting ranges.
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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