asp.net - check uploaded file in vb.net -


i need snippet check file validity (i'm allowing users upload xml files). need check whether uploaded file xml. best can think of check if extension ".xml". if replaced?

you can try loading , catch exception:

xdocument xdoc = xdocument.load("data.xml")); 

Comments

Popular posts from this blog

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

c# - SharpSVN - How to get the previous revision? -

php cli reading files and how to fix it? -