Skip to content

Instantly share code, notes, and snippets.

@datagy
Created March 25, 2020 21:54
Show Gist options
  • Select an option

  • Save datagy/df860917d920dd484a48b8606bbfc798 to your computer and use it in GitHub Desktop.

Select an option

Save datagy/df860917d920dd484a48b8606bbfc798 to your computer and use it in GitHub Desktop.
import openpyxl
files = [] # Insert paths to files here
for file in files:
wb = openpyxl.load_workbook(file)
sheet = wb['Sheet1']
sheet['F9'] = '=SUM(F5:F8)'
sheet['F9'].style = 'Currency'
wb.save(file)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment