title: Excel: how to get column index number for the last column when the last column changes number
body: <p>I'm trying to automate my VLOOKUPs for a data sheet that gets updated every week. At the moment my VLOOKUP looks like this:</p>
  
  <pre><code>=VLOOKUP(A3,'[Report.xlsm]All'!$I:$OA,COLUMN('[Report.xlsm]All'!$NX:$NX)-8,0)
  </code></pre>
  
  <p>Every week two new columns are inserted to the table (before the last column). The new columns are populated with new data and I have to re-write my VLOOKUP.</p>
  
  <p>The columns I'm looking up are always the third last, second last, and last columns.</p>
  
  <p>Is there a way I can assign column index number with a function that looks up third last, second last, and last columns? I think that way I can add a macro that does the job for me.</p>