Currently, we are working on a project. During the process, we found that the usercontrol placed in updatepanel had some problems during parsing.
Code
<Uc1: AAAA/> and <UC2: RRRR/> are two usercontrols used for testing. The buttons are used to prevent uc1 from being displayed and UC2 from being displayed. uc1 is displayed by default during loading, UC2 does not display (visible). When there is no outer updatepanel, load it and view the page source code. At this time, you will find that only uc1 is parsed and UC2 is not parsed, after you click the button, you will find that you are viewing the source code, only parsing UC2, but not parsing uc1. This is of course the same as my original intention, but when the outer layer contains updatepanel, after the initial loading or clicking the button, you cannot find the UC2 shadow when viewing the page source code, but the actual content of UC2 is displayed on the page, in this way, when UC2 contains a Javascript script, it cannot find the object resource and reports an error.
I have not figured out the reason yet. If any expert knows the reason, please leave a message to explain it. I am very grateful. I will continue to study this question to see why?