[
  {
    "Id": "244471",
    "ThreadId": "71671",
    "Html": "<p>Hi Cheeso</p>\r\n<p>the directory is &quot;D:\\test01&quot;, there are many child files and directories under it, i want to compress &quot;D:\\test01&quot; except the files &quot;D:\\test01\\bin\\help.chm&quot;, &quot;D:\\test01\\readme.txt&quot;,</p>\r\n<p>if my code is as following:</p>\r\n<p>zip.AddSelectedFiles(@&quot;name != .\\bin\\help.chm and name != readme.txt&quot;, @&quot;d:\\test01&quot;, true);</p>\r\n<p>the &quot;readme.txt&quot; is excluded successfully, but the &quot;D:\\test01\\bin\\help.chm&quot; is added in zip archive.</p>\r\n<p>&nbsp;</p>\r\n<p>if my code is as following:</p>\r\n<p>zip.AddSelectedFiles(@&quot;name != help.chm and name != readme.txt&quot;, @&quot;d:\\test01&quot;, true);</p>\r\n<p>the &quot;readme.txt&quot; and &quot;D:\\test01\\bin\\help.chm&quot; are  excluded successfully. And the &quot;D:\\test01\\help.chm&quot; is excluded too, i want to add the &quot;D:\\test01\\help.chm&quot; to zip archive.</p>\r\n<p>&nbsp;</p>\r\n<p>Doesn't the filename not include relative path when i write the selector criteria??</p>\r\n<p>&nbsp;</p>\r\n<p>&nbsp;</p>",
    "PostedDate": "2009-10-11T18:22:46.843-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "244474",
    "ThreadId": "71671",
    "Html": "<p>if there is a empty directory under the &quot;D:\\test01&quot;, the empty directory is not added in the zip archive.</p>\r\n<p>&nbsp;</p>",
    "PostedDate": "2009-10-11T18:26:55.72-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "244564",
    "ThreadId": "71671",
    "Html": "<p>To answer your question about the relative paths.&nbsp;. .</p>\r\n<p>I think the full path is included in the name, when you select in a directory specified with an absolute pathname, like d:\\test01 .&nbsp; Maybe the criteria you want is:</p>\r\n<p>&quot;name != *\\bin\\help.chm and name != readme.txt&quot;</p>\r\n<p>or you could specify the full path, as with this:</p>\r\n<p>&quot;name != d:\\test01\\bin\\help.chm&nbsp;&nbsp; and&nbsp; &nbsp;name != readme.txt&quot;</p>\r\n<p>In answer to your second post - about the empty directory - I think you&nbsp;are correct.&nbsp; It is a file selector, so the way I coded it, it does not select directories.&nbsp;</p>\r\n<p>&nbsp;</p>\r\n<p>&nbsp;</p>",
    "PostedDate": "2009-10-12T01:42:04.067-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "244867",
    "ThreadId": "71671",
    "Html": "<p>thanks,</p>\r\n<p>I get all empty directories first, add them to the zip archive through the AddDirectoryByName.</p>\r\n<p>&nbsp;</p>",
    "PostedDate": "2009-10-12T17:10:10.317-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  }
]