Excel/index and martch formula
I have a range containing information (D2:P7). In row 2, from E2 onwards, are the months of the year. In column D from D3:D7, are the names of students. In range E3:P7 are scores for students in a particular month. So, cell G4 would contain the score for a student in March.
I am trying, without success, to write a formula that will index and match a student (written in cell A3) with a month (written in cell B3)
So that, if I write, say Joseph in cell A3 and September in cell b3, the score for Joseph in September wil appear in cell C3.
Could you help me with this please?
Thanks in advance.
So we can find what column in the Index range by matching the month to the range of months in E2:P2. This will be the third argument to the INDEX function.
In the second argument, we lookup the name in A3 in the range of names D3:D7.
So in your example, the above formula resolves to
then this picks out the number in M5 that is 25.
Formula was tested and worked for me.
You can suppress error messages by doing
Tested in Excel 2013 and worked for me. Should work in Excel 2007 to current version. Just the base formula first shown should work in all versions. (IFERROR introduced in Excel 2007)
This topic answers questions related to Microsoft Excel spreadsheet (or workbook) stand-alone or Mircrosoft Office Excel including Excel 2003, Excel 2007, Office 2000, and Office XP. You can get Excel help on Excel formulas(or functions), Excell macros, charting in Excel, advanced features, and the general use of Excel. This does not provide a general Excel tutorial nor the basics of using a spreadsheet. It provides specific answers to using Microsoft Excel only. If you do not see your Excel question answered in this area then please ask an Excel question here