0 votes
by (330 points)
edited

Hi,

I would like to get the filename from a POP connection. It works fine. However, if the filename contains a '%', it uuencode to '%25'. How do I disable it?

e.g.

my filename is 'Sales forecast with 50 % market shares.doc'

string filename = message.Attachments[0].FilenName ;

The result is filename : 'Sales forecast with 50 %25 market shares.doc'

I am using c#.NET

Many thanks, Eddie

Applies to: Rebex Secure Mail

1 Answer

+1 vote
by (144k points)
edited
 
Best answer

This looks like a side-effect of a routine that "fixes" characters that are invalid for a filename. We will fix this issue in the next release. In the meantime, please use this instead:

string filename = message.Attachments[0].FileName.Replace("%25", "%");

Sorry for inconvenience, and thanks for letting us know about this!

by (330 points)
Thanks Lukas, no problem. We can work around that. Cheers
...