Handling events of usercontrols within listview

后端 未结 2 1022
孤街浪徒
孤街浪徒 2021-01-24 16:06

I have a simple usercontrol which raises an event on button click

Public Class UcPaymentCheque
    Inherits System.Web.UI.UserControl

    Public Event OnCancelC         


        
2条回答
  •  星月不相逢
    2021-01-24 16:29

    You can add the handler in the declaration of the user control in the listview, using OnCancelClick, as follows:

    
        
            
        
        
            
        
    
    

    Where UcTPPaymentCheque_OnCancelClick is the function you should use to handle the event, in the control that contains the listview.

提交回复
热议问题