Click here to Skip to main content
15,908,437 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have a FileUpload control .When ever i click on Browse button there need to be dispayed only ppt files in the browser window to select from.Is there a way for this ??
Posted
Comments
Sergey Alexandrovich Kryukov 9-Feb-12 2:39am    
To best of my knowledge, the problem is: browsers do not support it. Ugly problem, I would say. You can only validate the file name after the users selected it, issue warning, etc.
--SA
Abhinav S 9-Feb-12 2:51am    
That is indeed a bad problem.

1 solution

The easiest way to do this after the file is chosen, validate via Javascript.
Shown here[^].

You can also do validations via C# if you so require.
 
Share this answer
 
Comments
Espen Harlinn 9-Feb-12 8:36am    
5'ed!
Abhinav S 9-Feb-12 12:07pm    
Thank you Espen.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900