troubleshooting Question

Python - writing to a .csv file

Avatar of csehz
csehzFlag for Hungary asked on
6 Comments1 Solution181 ViewsLast Modified:
Dear Experts,

I have a small Excel file with the data as it the below print screen shows:
Excel file
which are imported by Python through a .csv file by the following code:
import csv

with open(r"C:\Users\ac324485\Downloads\Daily files\File.csv") as csvfile:
    rows = list(csv.reader(csvfile))
    data_header = rows[0]
    data_rows = rows[1:]
for x in data_header:
for x in data_rows:

Could you please advise which Python syntax could write back data to that Excel file to cell A2 (so to the place of value '10101')?

Thanks in advance,
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 6 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 6 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros