Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
not printing soup data to csv
#2
Hey dude.

So using the same settings in regards to .csv i created something simple to check that there wasn't an issue there which there of course should not have been..

import csv

tr = ["434", "3434", "23", "4523423", "423", "654", "234", "34", "54", "65", "234", "654", "5647", "345", "234"]

csvFile = open("booking_data.csv", 'wt', newline='', encoding='utf-8')
writer = csv.writer(csvFile)
for cell in tr:
    writer.writerow(cell)
    print(cell)
csvFile.close()
Everything worked fine.

Are you getting the table data printing to console?
Reply


Messages In This Thread
not printing soup data to csv - by rickyrt - Sep-17-2020, 02:52 AM
RE: not printing soup data to csv - by Aspire2Inspire - Sep-17-2020, 12:07 PM
RE: not printing soup data to csv - by rickyrt - Aug-31-2021, 03:41 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Soup('A') new_coder_231013 5 7,374 Oct-13-2024, 06:19 AM
Last Post: Pedroski55
  how to store data from the soup in the loop? zarize 1 2,251 Mar-02-2020, 04:17 PM
Last Post: Larz60+
  strange characters after printing soup zarize 4 3,208 Jan-28-2020, 08:57 AM
Last Post: zarize

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020