.net - How to safely save file to disk without the risk of windows reject it? -


i'm developing winform application. want take input user (i.e. user provides username) , use input part of filename , save file.

how check if username provided user didn't contain windows' reserved characters. , list of reserved characters windows?

via:

    path.getinvalidfilenamechars() 

and

    path.getinvalidpathchars() 

the exact list could platform-specific (especially mono), , includes non-printable characters... showing them here tricky ;p


Comments

Popular posts from this blog

c++ - Is it possible to compile a VST on linux? -

java - Output of Eclipse is rubbish -

jquery - Confused with JSON data and normal data in Django ajax request -