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 / March 2008

Tip: Looking for answers? Try searching our database.

Showing The Download Dialog Box?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Husam - 17 Mar 2008 11:12 GMT
Hi EveryBody:

I was downloading a lot of file by using the following code:

Response.AddHeader("Content-Disposition", "attachment; filename=" + filename)
response.BinaryWrite(buffer() as byte)
     
but I discover for large data this will be a problem because every time I
tried to download large data I error raise toled me that system out of memory.

I tried another way to upload and download to web server that really worked
with me very well but I face a problem when I download any file and I did not
use the response for writing it that the Download dialog box dose not appear
so some body can help me and toled me how can I use
My.Computer.Network.DownloadFile
or WebClinte class download method and still can show the download dialog
box I
tried
Response.addheader(value as string,name as string) but did not work.

any help will be appreciated

reagard's

Husam
Alexey Smirnov - 17 Mar 2008 12:32 GMT
> Hi EveryBody:
>
[quoted text clipped - 21 lines]
>
> Husam

What .NET version do you use?

There is a fix for 1.0-1.1, see http://support.microsoft.com/kb/823409
Husam - 17 Mar 2008 13:16 GMT
I am using ASP.Net 2.0 version

> > Hi EveryBody:
> >
[quoted text clipped - 25 lines]
>
> There is a fix for 1.0-1.1, see http://support.microsoft.com/kb/823409
Fred - 17 Mar 2008 13:13 GMT
Dans : news:D0A0E70D-702C-4560-8431-1384F4ED49AC@microsoft.com,
Husam disait :
> Hi EveryBody:
>
[quoted text clipped - 6 lines]
> time I tried to download large data I error raise toled me that
> system out of memory.

Another idea :
The default max length (with .NET 2.0) is 4Mb.
Did you check this ?
Add this element to your your web.config if not.
<httpRuntime maxRequestLength = "..." />

PS : I use Me.Response.TransmitFile

Signature

Fred
foleide@free.fr

Fred - 17 Mar 2008 13:25 GMT
Dans : news:evMCZhCiIHA.4344@TK2MSFTNGP03.phx.gbl,
Fred disait :
> Dans : news:D0A0E70D-702C-4560-8431-1384F4ED49AC@microsoft.com,
> Husam disait :
[quoted text clipped - 16 lines]
>
> PS : I use Me.Response.TransmitFile

Sorry, This is for upload ...

Signature

Fred
foleide@free.fr


Rate this thread:







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.