RSS Forums RSS
Please support our ASP.NET advertiser: Lunarpages ASP Web Hosting

Open file Dialog in asp.net

Join Date: Nov 2007
Posts: 18
Reputation: Nareshp_123 is an unknown quantity at this point 
Rep Power: 2
Solved Threads: 0
Nareshp_123 Nareshp_123 is offline Offline
Newbie Poster

Question Re: Open file Dialog in asp.net

  #3  
Nov 15th, 2007
Originally Posted by Fungus1487 View Post
you cant hide the textbox but if you set the display style property of the FORM element to 'none' and create another element of type button then using javascript you can open the dialog onClick of the button e.g.

<form name="form1"/>
    <input type="file" name="filediag" style="display:none" />
    <input type="button" value="browse..." 
            onclick="document.form1.filediag.click()" />
</form>


thanks for giving it in minimum lines of script.
I had already done it upto that extent(of which i am able to get path of the file into textbox(which is not visible)but with more number of lines)ok.
but now what my question is that
after opening the 'Choosefile'dialog onClick of button('browse')
and select one (ex:- *.xml) file ->click on 'Open' button on 'Choosefile'dialog .then
it should open that file in a new browser or some editor.
Reply With Quote  
Forums | Blogs | Tutorials | Code Snippets | Whitepapers | RSS Feeds | Advertising
All times are GMT -4. The time now is 4:14 am.
Newsletter Archive - Sitemap - Privacy Statement - Acceptable Use Policy - Contact Us
Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC