Python Forum
Data in excel - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: General Coding Help (https://python-forum.io/forum-8.html)
+--- Thread: Data in excel (/thread-14439.html)



Data in excel - Hass - Nov-30-2018

Hello,

I am new to python so apologies advance if this question doesn’t make sense.

I have an excel file that has 2 sheets.

Sheet 1 is where the formulas are and sheet 2 is where the raw data is.

Can someone point me in the right direction as to how I can automatically get the raw data for each day put it into the formulas record the output to a separate sheet then move on to the raw data for the next day and keep repeating the process until all the raw has been put into the formula and the output recorded.

I would like if someone can point me in the right direction and if possible give me some code that I can modify for my application.

Thanks in advance.


RE: Data in excel - nilamo - Nov-30-2018

openpyxl is the go-to package for working with excel files in python. https://openpyxl.readthedocs.io/en/stable/

If you could share a sample doc, with some forumulas, and two or three lines of sample data, we could maybe help out more. But that package is definitely a good starting point, as it allows you to read values, create new sheets, and save the edited excel doc.