Could not find UpdatePanel with ID 'xxx'. If it is being updated dynamically then it must be inside another UpdatePanel

前端 未结 10 1497
终归单人心
终归单人心 2021-02-05 10:08

I have a page with Ajax Tab controls, within one of the tabs is a webcontrol that as a Telerik RadGrid, with Edit forms pointing to another web control. That edit form also cont

10条回答
  •  醉梦人生
    2021-02-05 10:24

    EDIT: I'd like to revise my answer based on some new things I discovered while working with update panels in UpdateMode="Conditional".

    This is still in context of addressing the OP's issue of encountering the above error.

    The scenario for me is that I have a parent update panel with several nested child update panels:

        
            
                <%-- Header Content --%>
                
                    
                        <%-- Child1 Content --%>
                    
                
                
                    
                        <%-- Child2 Content --%>
                    
                
                
            
        
    

    In order for the Edit button to change content in both child update panels and also refresh the overall Parent update panel without causing any issues, you might want to consider doing an asynchronous postback:

        
            
                
            
            
                <%-- Header Content --%>
                
                    
                        <%-- Child1 Content --%>
                    
                
                
                    
                        <%-- Child2 Content --%>
                    
                
                
            
        
    

    This works for me, I don't get the above mentioned (OP's) error any longer. Interestingly enough, almost similar to the OP's scenario, I've been working with Ajax Tab Controls and each tab contained child update panels. This is where I've encountered the exact same error message and resolved it by adding the asynchronous post back trigger.

提交回复
热议问题