Partial Rendering without Ajax?

G

Guest

I am trying to figure out how to do a postback that updates only changed
controls without having the entire page refresh and flash on the screen.
Seems to me this was available in ASP.NET 1.1, but I can't remember how it
was done (I did it in another project but can't remember how).

I do not want to use Ajax.

I tried a search but got so many hits related to Ajax that I gave up.

Thanks

Robert
 
T

Teemu Keiski

You can set SmartNavigation="true" on Page directive. It's the previous
mechanism (in ASP.NEt 1.x, obosolete but exists in v2.x) to prevent refresh
on postbacks, and to keep scroll positions etc.
 
R

Rbrt

Tried that. Now I get Stack Overflow on Line 0 if I click the submit button
more than once. This message comes after all the events in the page have been
fired, so I'd say the feature is not so well supported any more. Am I missing
something?
 
T

Teemu Keiski

Nope, SmartNavigation didn't (doesn't) work out well so, best way *really*
is to stick to ASP.NET Ajax or some commercial Ajax library. In ASP.NEt 2.0
you certainly can use client callbacks (call backs to server-sise code) too,
in case you just want to deal with the client-side yourself

In ASP.NET 2.0 scroll position can be kep by using
MaintainScrollPositionOnPostBack="True" to @Page directive. Focus can be set
with SetFocus method of the Page.
 
R

Rbrt

You work a long day!

I figured out why I was getting the error. I also had
MaintainScrollPositionOnPostBack="True" set in the page. When I removed that,
the stack overflow went away. Apparently IE is not too happy with both turned
on. Thanks!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,008
Latest member
obedient dusk

Latest Threads

Top