You use the following declaration to add a Web user control named TestUserControl.ascx to an ASP.NET page named TestPage.aspx.
- A、Add the following line of code to TestUserControl.ascx.cs. public event MyEventHandler MyEvent;
- B、Add the following line of code to TestUserControl.ascx.cs. public MyEventHandler MyEvent;
- C、Replace the TestUserControl.ascx reference in TestPage.aspx with the following declaration. <uc:TestUserControl ID="testControl" runat="server" OnMyEvent="TestMethod"/>
- D、
Replace the TestUserControl.ascx reference in TestPage.aspx with the following declaration. <uc:TestUserControl ID="testControl" runat="server" MyEvent="TestMethod"/>
正确答案:A,C
答案解析:有
微信扫一扫手机做题