title: Fake Path for Executable python
body: <p>I have a folder structure in this format:</p>
  <p>./code.py</p>
  <p>./data.xlsx</p>
  <p>The code below works great when I run it in the terminal with the command</p>
  <pre><code>import win32com.client as win32
  from datetime import datetime
  import os
  import pandas as pd
  import xlsxwriter
  
  co = os.path.join(os.path.dirname(os.path.realpath(__file__)),'data.xlsx')
  df= pd.read_excel(co,sheet_name = 'sheet1')
  </code></pre>
  <p>python code.py</p>
  <p>However, when I convert to .exe with auto-py-to-exe the script stops working because it cannot find the .xlsx file. An error message appears where a temporary windows folder is displayed and logically the .xlsx file is not found.</p>
  <p>How do I convert from .py to .exe so that the relative path is not a temporary folder when it runs.</p>