Extracting file containing ~ (tilde) to UNC path causes Invalid Characters in Path Exception

Sep 27, 2011 at 3:04 PM
Edited Sep 27, 2011 at 3:11 PM

Hello,

I'm encountering a problem extracting a file containing a tilde (~) in the file name to a UNC path as the destination folder where I am catching an exception of "Invalid characters in path". Has anyone seen this issue or can offer any advise on how to resolve it?

In attempt to anticipate questions:

I have to use a UNC path to avoid long file path issues.

I'm able to successfully unpack the file using Windows Explorer.

I've got full control on the destination server I am unpacking to.

I've attempted to enumerate through each entry and unpack as well as use ExtractAll().

Thanks!

Sep 27, 2011 at 3:22 PM

Disregard. On closer inspection, I discovered the zip entry that was throwing the exception on extract contained a carriage return at the end of the filename property.