Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / General / September 2007

Tip: Looking for answers? Try searching our database.

Upload file inside AJAX updatepanel - new solution

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Bjorn Sagbakken - 26 Sep 2007 20:04 GMT
I was looking for a solution, without the full page postback, and all the
tip was about a hidden iframe and RJS.
The RJS was not known to me before, and still I haven't explored this used
with ASP.NET

But, the iframe issue gave me an idea; why not put the fileupload control &
a submit button on a form, nothing else. Then on my main form I added an
iframe, a visible one, with src=the form with the file upload control.

Ok, this shows very nice in the browser, no one will see that a small part
of the main form actually is another form. Next, on hitting the file submit
button, the file is actually uploaded to a temp folder on the server -
without the page beeing posted back! On doing this I also write the uploaded
filename to a session variable, so the "Save" button on the main form can
attach to the file for further proccessing, and finally delete the temp
file.

I am kind of new to AJAX so maybe I'm stupid, but nevertheless this approach
actually works.

Bjorn
bruce barker - 26 Sep 2007 21:08 GMT
this is pretty standard. most web based email systems use this for
attachments.

-- bruce (sqlwork.com)

> I was looking for a solution, without the full page postback, and all the
> tip was about a hidden iframe and RJS.
[quoted text clipped - 17 lines]
>
> Bjorn
Bjorn Sagbakken - 26 Sep 2007 21:54 GMT
Maybe so. Since I am quite new with AJAX, this local event still gave me a
good feeling - to re-invent a small wheel....

Bjørn

> this is pretty standard. most web based email systems use this for
> attachments.
[quoted text clipped - 22 lines]
>>
>> Bjorn

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.