I have a excel workbook that I convert into a dataframe but I'm trying to rea each row and column and assign variables but the problem is the data is not always in the same place so I can't hardcode the location of the data. So I capture the first row and first column and I'm just trying to search them to find the data and get the location.
Here is my code:
wb = load_workbook(strTotalFile,data_only = True)
for sheet in wb.sheetnames:
ws = wb[sheet]
data = ws.values
pd.set_option('display.max_columns', None)
df = pd.DataFrame(data)
mainRow = df.iloc[[17]]
mainCol = df.iloc[:,1]