.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Connection time out + excel file upload + ajax async as a fix?

Posted By:      Posted Date: October 19, 2010    Points: 0   Category :ASP.Net

Thank you in advance for taking the time to read this.

I have a C# ASP.NET page that allows users to select 2 excel files from their machine and click a button to compare and look for differences.  Any difference is output to a gridview for them to review.  The code works brilliantly on my machine, on other machines inside our network, ect but when we try to access this page from outside the network and use excel file sizes around 1mb a piece, we're seeing a connection timed out error in IE (v6 and v7).

Due to limitations beyond my control, I can not save the files to the server first and then do my comparison code.  Instead I have to read the files to memory and am using a .dll found here, http://exceldatareader.codeplex.com/.  It basically reads the excel files into datasets, which are then passed on to my comparison method.

What appears to happen is that the comparison code takes some time, depending on the file size.  For example, 20kb Excel files net results with no errors in just a few seconds.  200kb files take longer but still succeed.  1mb files, though, get the connection timed out but only in IE and only outside our network.

So my thought was that perhaps the browser isn't getting the results back from the server fast enough and issues the connecti

View Complete Post

More Related Resource Links

Ajax & Async File Upload Control

i want to use new Async File Upload Control without updating the new dll.because in new dll modal popup extender and link button generates postback.I want to devlop a same control is there any way to develop Async File Upload Control?Can we use the Source Provided in Ajax Tool Kit?

Insert Excel Data via File Upload into sql server database???

Hi all, I have requirement that User can Upload the Excel Sheet Data to sql server Database at once. How i do that Any Article or hint is apperciated.   Regards 

Best way for Async File Upload

Hi experts,I need to upload files asynchronously, in a user friendly manner.Do asp.net provide any such control/toolkit?What is your suggestion for async file upload for my new website? Should I use any 3rd party control?Thanks for your reply in advance.

Need to find File Share Excel Rendering time--SSRS 2008

we are using SSRS 2008 file share subscription to generate EXCEL reports,Requirement here is need to find the file rendering/completion time in order to send the excel file as attachement using xp_senddbmail. Your help is highly appreciated-- Sathish

File upload using AJAX.BeginForm

Hi Everyone,I am new to ASP.NET 3.5 MVC, I want to upload file using AJAX form. When I am using html form then I am able to upload files but my requirement is that I am using user control for edit profile, I am using tabs for the same where in we are having multiple tabs for edit profile, change password, etc.While using AJAX form having enctype = "multipart/form-data" then following statement did not get the files foreach (string filename in Request.Files)Please help me find the solutionThanks in advance

For MYSQLMemberShipProvider read the connection string from external file at run time

Hi, In my asp.net mvc application, I have used "MYSQLMemberShipProvider" .I want to read connection string from external file at run time.I am using MYSQL connectore 6.3.4How can I do thatThanksAayushi

Ajax file upload: example needed



So far, I have built a MVC application that has a file upload form. The upload is done the "old" way, i.e. with a full postback.
Now, I wish to do the upload in the background using AJAX. There are a lot of samples for asp.net, but no for MVC.

Could someone give me an example of an upload form using AJAX in a MVC application?
How can I change my application to work with AJAX?

Thanks a lot for your help.


While building my excel file, do an ajax call



I'm in trouble here because of a little problem.

In fact, in my MVC project, I have a controller which build a Excel file and the return value is a FileResult.

for now, I'm using this like that :

<form id ="TransacExportForm" method="POST" action="/theproject/thecontroller/theaction" style="display:none;">


With the javascript :


As I expected, after 25 seconds, the browser send the window popup to download the file (which is what I want)

It works perfectly, but it's so long... It's why I would do some ajax calls in order to have a "loading gif", and when the file is "created", the browser send the message to download the file.

I tried a loooot of things (get, ajax, etc...). The file is created but the browser don't send any message to download the file.

If someone could give me an answer, it would be very great :D !

Import Excel file with Data Connection into SSIS


I have got an Excel spreadsheet with a Data Connection that I want to import into SSIS. The problem is that the Data Connection does not seem to run at the time the file is imported, so it only calls "old" data.

How can I set SSIS up to run the Data Connection first, or is there something I need to change in my Excel spreadsheet setup?

When a person opens the Excel file normally, they first need to "Enable" the Data Connection in the Security Settings. Once that is done the data will update immediately. I wonder if that is something I somehow need to change to make it work in SSIS?

upload excel file to sql table


i tired a lot of correction, in the end i end up fully used the completely same code and guide of this link.


that was a well step-by-step guide through.

the error i get was, i found out it didnt save the file into table.
from the table under the file column
it show

if i click on download the file
error code shown,
There is no row at position 0.

Source Error:
Line 111:        Dim bytes() As Byte = CType(dt.Rows(0)("file1"), Byte())

can anyone teach me? thanks..

OLEDB Connection for Excel not a valid file path


Hi there, I'm using a FileUpload control on a webform to allow users to select an excel file. I then want to read the excel file and dump the data into a dataset, but I can't get it to work. This is my code:

Dim fileNameString As String = Me.BillUpload.FileName
Dim filePathString As String = Me.BillUpload.PostedFile.FileName
Dim fileLength As

Upload Multiple File using JQuery in asp.net

In this article I have explained how to upload multiple files using file upload control. I have used jQuery plugin for uploading multiple files.

I have also explained how to check for file type, file maximum size limit using jQuery & also using server side validation code.

Creating Excel file from C#

I used below coding for create a excel sheet.I got from on web site.
In below coding there is no problem.Its create the excel file.If i run second time,its ask to overwrite the current excel file.If I said "Yes" then it ok ,but If I select cancel button,its generate the Error message.The exception is

Upload a File to a SharePoint Document Library - Part I

The following helper class demonstrates a few techniques that allow documents to be uploaded to a SharePoint document library programmatically without using the API or a custom web service. You don't need to specify a document library name, and it will create any folders specified in the URL as required. File meta data will be updated if any properties are passed.

Multi File Upload Using JQuery!

Everyone knows about the file upload in .NET. But the multi file upload is some what difficult in .NET. For that purpose we can have some AJAX or JQuery!. Jquery is the latest advanced version. It will give some animated upload. You can try it for your own!!!!

The Free Barcode Creator produces barcode images one at a time, and allows easy saving to a file or

The Free Barcode Creator produces barcode images one at a time, and allows easy saving to a file or pasting into an application. 2D versions are also available:

file upload in chunks or not buffering in memory before writing to disk?


What are the options for handling file uploads to reduce the memory footprint?  Is there a way to upload in chunks?  Is there a way to stream upload directly to disk instead of loading entire file in server memory?


ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend