473,385 Members | 1,372 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,385 software developers and data experts.

GridView EditButton: Automatically scroll down to row?

Hi; I'm implementing a fairly simple database table editting form in
ASP.NET 2.0 using the gridview. I enabled AutoGenerateEditButton to
add row editting functionality. One little quirk I'd like to iron out:
when I click the edit button, the page is reloaded at the _top_ of the
page, instead of at the row I clicked. So if I click to edit the 200th
row, I have to scroll all the way down to it, which is a great big
hassle. Any workarounds?

alonzo

Mar 26 '07 #1
1 5012
Hello,
add this to the @Page directive:

MaintainScrollPositionOnPostback="true"

Bruno

"alonzo" <al*********@mailc.netwrote in message
news:11**********************@p15g2000hsd.googlegr oups.com...
Hi; I'm implementing a fairly simple database table editting form in
ASP.NET 2.0 using the gridview. I enabled AutoGenerateEditButton to
add row editting functionality. One little quirk I'd like to iron out:
when I click the edit button, the page is reloaded at the _top_ of the
page, instead of at the row I clicked. So if I click to edit the 200th
row, I have to scroll all the way down to it, which is a great big
hassle. Any workarounds?

alonzo

Mar 27 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: tfsmag | last post by:
I'm having a weird problem with the rowdatabound event for a gridview in my application... Here is the code. -------------------------------------- Protected Sub AnswersGrid_RowDataBound(ByVal...
1
by: Mike P | last post by:
When you use a SqlDataSource to hook up data to a GridView it seems to be to be very inflexible. For example, I want to create my own Delete button with my own code and I also want to create a...
0
by: Mike P | last post by:
I have a couple of columns in my gridview that I am adding formatting to in the RowDataBound event. But when I want to edit the rows when the RowDataBound event gets called, I get an error. I'm...
1
by: dba56 | last post by:
I have a gridview on an ASP.Net 2.0 web site that is longer than the web page. When a user navigates to a row off the page and clicks on the edit button on the row the page refreshes (posts back?)...
0
by: Mike P | last post by:
I am trying to edit a gridview while using paging, but whenever I try to edit a row on a page other than page 1, I get an error. Here is my gridview and my code : <asp:GridView ID="GridView1"...
0
by: DC | last post by:
The problem I'm using the .NET GridView and FormView objects for the first time and im getting the error "An OleDbParameter with ParameterName '@ID' is not contained by this...
1
by: Axeman | last post by:
I have an AJAX enabled web form with several data-filled GridView controls. The users accessing this web app will navigate the site via touch-screen monitors (i.e.: no mouse). As a result, I need...
0
by: Larry Bud | last post by:
After spending two days looking at the options in adding a row to a gridview, I came up with my own that I'd like to share. I only can share pseudo-code right now, but maybe in the future I'll...
1
by: madhurisajja | last post by:
Hi All, I have a Gridview inside a Panel and i have set overflow to auto for the scroll bars to appear. I have a server side code that handles the up and down key arrows. The problem i have is...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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...

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.