views:

21

answers:

1

I am porting an ASP.NET application from 3.5SP1 to 4.0. The application works perfectly in 3.5SP1. In 4.0, I am seeing a difference in UpdatePanel behavior.

We have a simple user control with a testbox, a button, and some text. The user control lives inside an UpdatePanel with UpdateMode="Conditional" and ChildAsTriggers="true".

Users type into the textbox and click the button. We do a search. If we find something, content elsewhere on the page is updated - this works great. If we don't find it, we change the text in the user control. That change never appears.

So I know the button and logic is working. The user control does not own the UpdatePanel it lives in, and it would be nice if it didn't have to. But even though the button is raising an event back to the server, the update panel content is not updating.

Has anyone seen this?

A: 

My problem turned out to be 4.0's new client-ID mechanism. Check out the new features here.

4.0 defaults to 'Inherit' while 'autoID' is the 'old' behavior. By adding this to the web.config pages element:

clientIDMode="AutoID"

my problem went away. I'm not wild about forcing backward-compatible behavior but until I can sort thru all the control relationhips this will have to do.

n8wrl

related questions