C#: Writing a CookieContainer to Disk and Loading Back In For Use
I have a CookieContainer extracted from a HttpWebRequest/HttpWebResponse session named CookieJar . I want my application to store cookies between runs, so cookies collected in the CookieContainer on one run of the program will be used the next run, too. I think the way to do this would be to somehow write the contents of a CookieContainer to disk. My question is: How can you write a CookieContainer to the disk ? Are there built-in functions for this, or, if not, what are the approaches people have taken? Are there any classes available for simplifying this? Once you've written a