streamwire 0 Posted September 4, 2012 Report Share Posted September 4, 2012 hey, i´m new around here, so bare with me :-) i just finished my first ever bot that collects urls from YT.so how can i save the data to a file without erasing the old data inside the file? everytime i use the "save to file" command, the old scraped data gets overwritten. hlp Quote Link to post Share on other sites
TheMentalist 4 Posted September 4, 2012 Report Share Posted September 4, 2012 1) Read existing data into list 1. 2) Scrape new data into new list 2. 3) Add list 2 to list 1 4) Write list 1 back out. So, effectively, you are adding the new URLs to the old URL's then writing the new collection back out, erasing the existing file but replacing it with the newer file with the old and new data combined. 1 Quote Link to post Share on other sites
Condorbots 0 Posted September 26, 2012 Report Share Posted September 26, 2012 To Willywonda and The Mentalist, thanks. I am trying to do something similar, in terms of adding content to a saved file. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.