页面加载时重置了与服务器的连接 [英] The connection to the server was reset while the page was loading

查看:113
本文介绍了页面加载时重置了与服务器的连接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要在gridview中显示4000多个数据。我使用datatable检索所有这些并在gridview中传递它们。但系统在gridview中加载500-600行后显示此错误 -



连接已重置



页面加载时重置了与服务器的连接。



该网站可能暂时不可用或太忙。稍后再试。

如果您无法加载任何页面,请检查计算机的网络连接。

如果您的计算机或网络受防火墙或代理保护,确保允许Firefox访问Web。



i尝试不同的技术 -



1. httpruntime executiontimeout =1800maxrequestlength =51200

2. adapter.SelectCommand.CommandTimeout = 1800;

3.连接字符串中的连接超时= 1800。



但注意到了。它在localhost中运行完美,但在实时服务器中失败



请帮助

I need to show 4000+ data in a gridview. i retrieve all of them using datatable and pass them in gridview. but system show this error after load 500-600 row in gridview -

The connection was reset

The connection to the server was reset while the page was loading.

The site could be temporarily unavailable or too busy. Try again in a few moments.
If you are unable to load any pages, check your computer's network connection.
If your computer or network is protected by a firewall or proxy, make sure that Firefox is permitted to access the Web.

i try different technique -

1. httpruntime executiontimeout="1800" maxrequestlength="51200"
2. adapter.SelectCommand.CommandTimeout = 1800;
3. Connection Timeout=1800 in connection string.

but noting happen. it works perfect in localhost but failed in live server

please help

推荐答案

您的页面/服务器没有因为你在做什么而能够回应。增加超时也是一个不值得推荐的肮脏技巧。



这不是一个很好的方式来一次显示网格中的大量数据,最终用户不会喜欢那么多延迟或挂起。



在显示数据时使用分页/过滤。



In数据库端

SQL Server 2005分页结果 [ ^ ]



在前端

GridView多重过滤器AJAX控件 [ ^ ]

具有分页和排序功能的转发器 [ ^ ]



此外,您应优化数据库。查看这些

在SQL Server中优化数据访问的十大步骤:第一部分(使用索引编制) ) [ ^ ]

在SQL Server中优化数据访问的十大步骤:第二部分(重新考虑TSQL并应用最佳做法) [ ^ ] [ ^ ]

前10名在SQL Server中优化数据访问的步骤:第IV部分(诊断数据库性能问题) [ ^ ]

优化的十大步骤SQL Server中的数据访问:第V部分(优化数据库文件并应用分区) [ ^ ]
Your page/server not able to respond because of what you're doing. And increasing timeouts are also dirty trick which is not recommendable one.

That's not a good way to show that much data at a time in grid, End user won't like that much delay or hangs.,

Use paging/filtering while displaying the data.

In database side
SQL Server 2005 Paging Results[^]

In frontend
GridView Multiple Filter AJAX Control[^]
Repeater with Paging and Sorting Features[^]

Besides you should optimize your database. Check these
Top 10 steps to optimize data access in SQL Server: Part I (use indexing)[^]
Top 10 steps to optimize data access in SQL Server: Part II (Re-factor TSQL and apply best practices)[^]
Top 10 steps to optimize data access in SQL Server: Part III (Apply advanced indexing and denormalization)[^]
Top 10 steps to optimize data access in SQL Server: Part IV (Diagnose database performance problems)[^]
Top 10 steps to optimize data access in SQL Server: Part V (Optimize database files and apply partitioning)[^]


这篇关于页面加载时重置了与服务器的连接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆