title: Using Python's Openpyxl for an index match
body: <p>I am trying to build a tool which will run an index match in a cell on a spreadsheet, and then display the result of the formula in python. My understanding is Openpyxl will not actually run the formulas but I can write to excel and then refresh the file to run it? </p>
  
  <pre><code>from openpyxl import load_workbook
  path= "C:\\Users\\Me\\Documents\\Python\\File.xlsx"
  myworkbook=load_workbook(path)
  worksheet=myworkbook.get_sheet_by_name('Sheet1')
  mycell=worksheet['B2']
  mycell.value="index(B4:B72,match(B1,A4:A72,0))"
  print(mycell)
  </code></pre>
  
  <p>Anyway, I receive and error and I am not sure what is going on. Ouput:</p>
  
  <blockquote>
    <p>DeprecationWarning: Call to deprecated function get_sheet_by_name (Use wb[sheetname]).
      worksheet=myworkbook.get_sheet_by_name('Sheet1')
    </p>
    
    <p>Process finished with exit code 0</p>
  </blockquote>
  
  <p>To be clear, the formula works if I just do it in Excel because B1 is populated in the file. </p>
  
  <p>I am not sure what the output is doing. It is not throwing an error but I have no idea what <code>&lt;Cell 'Sheet1'.B2&gt;</code> and  "Process Finished with Exit code 0" is trying to tell me.  I expected a string output because the I am trying to index in a sentence.</p>