470,616 Members | 3,211 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,616 developers. It's quick & easy.

Gridview, using Callbacks when Sorting and Paging

For some reason when I enable the callback feature of the gridview I
still get a page refresh, that is it seems like there is a postback
that occurs, not a callback which is just supposed to update not the
whole page, but a portion of the page.

Strangely enough the URL below


(VB GridView Paging and Sorting Callbacks example)

has a callback example for gridview which explains that there should
NOT be a page refresh, but it sure seems like the page refreshes
(flickers) when I run the example.

Also another example I found on the web on msdn

(Listing 4. Using Callbacks when Sorting and Paging section)

states that...

Client-Side Sorting and Paging
The GridView control provides you with the option of sorting and paging
records without requiring a form-post back to the Web server. In other
words, you can re-render the contents of a GridView when sorting and
paging, without needing to re-render the entire page.

You enable client paging and sorting by assigning the value true to the
EnableSortingAndPagingCallback property. When this property has the
value true, the GridView uses JavaScript to request an updated set of
records from the Web server.

I tried the piece of code that was provided...

<head runat="server">
<title>Callback GridView</title>
<form runat="server">

<%=DateTime.Now %>

Runat="Server" />

"Server=localhost;Database=pubs;Trusted_Connection =true"
SelectCommand="SELECT * FROM Titles"
Runat="Server" />

but even though sorting and paging callbacks are ENABLED, the TIME
which is NOT supposed to be updated, still gets updated everytime I do
a sort or change the page.

Does anyone have any idea why this is happening? Am I misunderstanding
the whole concept of callbacks? I made sure I am using the 2.0
framework and using ASP.NET 2.0, just because I installed Visual Studio
2005 on top of my existing Visual Studio 2003.

This sucks...I hope someone can shed some light for me into this.

Thanks for your time and help in advance.

Best Regards,

Tim :-)

Jul 21 '05 #1
0 2485

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

5 posts views Thread by yefei | last post: by
1 post views Thread by davidjgonzalez | last post: by
3 posts views Thread by Marc Grutte | last post: by
reply views Thread by Don Miller | last post: by
4 posts views Thread by Don Miller | last post: by
3 posts views Thread by Toni | last post: by
1 post views Thread by John A Grandy | last post: by
reply views Thread by =?Utf-8?B?R3JlZw==?= | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.