[
  {
    "Id": "211832",
    "ThreadId": "62410",
    "Html": "<p>Hello,</p>\r\n<p>I need to do what I believe is a common task but have found no discussion of the technique.&nbsp; An unattended program runs each night and add certain files to an existing Zip archive.&nbsp; I've fiddled around and come up with the technique below.&nbsp; However, I'm concerned it may not be the best way to do it, particularly as the Zip gets large.&nbsp;</p>\r\n<p>Is the example below reasonable?&nbsp;&nbsp; Thanks in advance!</p>\r\n<p>&nbsp;</p>\r\n<p>Using zip As ZipFile = ZipFile.Read(sArchivePath)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Try<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; zip.UpdateFile(sFilePath)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; zip.Save(sArchivePath)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Catch ex As Exception</p>\r\n<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ' Error handler</p>\r\n<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End Try</p>\r\n<p>End Using</p>\r\n<p>&nbsp;</p>",
    "PostedDate": "2009-07-14T12:26:59.903-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "211871",
    "ThreadId": "62410",
    "Html": "<p>If you are adding a single file, that is the correct way to do it!</p>\r\n<p>If you like, you can omit the sArchivePath in the Save().&nbsp;</p>\r\n<pre>  Using zip As ZipFile = ZipFile.Read(sArchivePath)\r\n        Try\r\n            zip.UpdateFile(sFilePath)\r\n            zip.Save()\r\n        Catch ex As Exception\r\n        ' Error handler\r\n        End Try\r\n  End Using\r\n</pre>\r\n<p>How large is the zip file?   Are you experiencing any real problems, or only doubts?</p>",
    "PostedDate": "2009-07-14T14:51:15.993-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  }
]