473,396 Members | 2,052 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Problems during Page Load

Okay, here's another one for you. Hopefully I can articulate my problem well enough...

I've got a GridView (with C# code behind) that is having some page load issues. Users can enter and manipulate data in the grid and occasionally this causes actions (such as record inserts, updates, validation, etc.) that require the data to rebind and the page to reload. My problem is that when this occurs, it causes the page to default directly to the beginning of the page. This can be pretty jarring and annoying.

In other words, suppose scroll down to the bottom of the page and manipulate some data. I enter a value in a dropdown list, which then causes an event to fire to populate some other columns. This then requires a rebind/reload to show the new data. However, during the reload, the page now shows the top of the page again. I have to scroll down to the bottom again to see the row that I was just manipulating. It can get pretty annoying.

Is there any way to prevent the page from resetting to the top on the reload?

I didn't notice this until just recently when the values in my GridView exceeded the size of my page.

Many thanks for any advice.

Robert
Apr 29 '08 #1
2 1384
Frinavale
9,735 Expert Mod 8TB
Okay, here's another one for you. Hopefully I can articulate my problem well enough...

I've got a GridView (with C# code behind) that is having some page load issues. Users can enter and manipulate data in the grid and occasionally this causes actions (such as record inserts, updates, validation, etc.) that require the data to rebind and the page to reload. My problem is that when this occurs, it causes the page to default directly to the beginning of the page. This can be pretty jarring and annoying.

In other words, suppose scroll down to the bottom of the page and manipulate some data. I enter a value in a dropdown list, which then causes an event to fire to populate some other columns. This then requires a rebind/reload to show the new data. However, during the reload, the page now shows the top of the page again. I have to scroll down to the bottom again to see the row that I was just manipulating. It can get pretty annoying.

Is there any way to prevent the page from resetting to the top on the reload?

I didn't notice this until just recently when the values in my GridView exceeded the size of my page.

Many thanks for any advice.

Robert
there is a Property of your ASPX Page called
MaintainScrollPositionOnPostback you could try setting to true. Or if this doesn't work you could consider adding paging to your GridView to reduce the number of records displayed at one time.

-Frinny
Apr 29 '08 #2
MaintainScrollPositionOnPostback did the trick. Many thanks!

Robert
Apr 29 '08 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Vincent | last post by:
I am trying to generate Excel worksheets using .Net. The worksheets are actually HTML pages with Excel specific XML elements. Everything works fine until I added these following code in the...
5
by: N | last post by:
Hi, I got an error during load on a couple of the tables. And it seems to be complaining that I'm running out of tempspace (possibly during index rebuild). Below is the load command and error....
3
by: TT (Tom Tempelaere) | last post by:
Hi there I am making a service project in C#, and I'm in the process of writing the installer. I made an installer class by using the "Add Installer" menu-item in the design window of the service,...
11
by: Glen Wolinsky | last post by:
This is my first attempt as asynchronous processing. I have created a small test app as proof of concept, but I am having one proglem. In the example (code listed below), my callback routine has...
1
by: John Cosmas | last post by:
I've got a page which loads up a different user control into a placeholder control every time a button is clicked on the parent page. I use a statement like...
1
by: S S Venkatesh | last post by:
Hi, I'm involved in a ASP.NET web project with a web farm and load balancing(windows server 2003 ) with no afinity (no sticky sessions) and i am facing problems in view state. I get an error...
3
by: Jéjé | last post by:
Hi, I want to dynamically load an ASCX control which contain a formview. And I want to render the result into a string. but I receive some errors like: Control 'FormView1' of type 'FormView'...
6
by: snazzy | last post by:
I have a problem where using innerHTML to rewrite a DIV or removeChild to kill a DIV that either of them, if excuted before the page is done loading will stop the page in its tracks. ...
3
by: PCgeek | last post by:
sorry moved this over to javascript forum, didn't mean to post 2x! Hi guys, I'm trying to put the finishing touches on my website and could really use some help on this particular issue. My page...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.