Control.Load 이벤트

정의

Page 개체에 서버 컨트롤을 로드할 때 발생합니다.

public:
 event EventHandler ^ Load;
public event EventHandler Load;
member this.Load : EventHandler 
Public Custom Event Load As EventHandler 

이벤트 유형

EventHandler

예제

// This is the constructor for a custom Page class. 
// When this constructor is called, it associates the Control.Load event,
// which the Page class inherits from the Control class, with the Page_Load
// event handler for this version of the page.
public MyPage()
{
   Load += new EventHandler(Page_Load);
}
' This is the constructor for a custom Page class. 
' When this constructor is called, it associates the Control.Load event,
' which the Page class inherits from the Control class, with the Page_Load
' event handler for this version of the page.
Public Sub New()
   AddHandler Load, AddressOf Page_Load
End Sub

설명

각 페이지 요청에서 발생하도록 설정된 모든 처리 단계를 수행하도록 서버 컨트롤에 알림 이 이벤트에서 상태 정보 보기 및 웹 양식 POST 데이터에 액세스할 수 있습니다. 페이지의 컨트롤 계층 내에서 다른 서버 컨트롤에 액세스할 수도 있습니다.

참고

이벤트 중에 컨트롤에서 사용자 지정 템플릿을 Page_Load 설정하면 사용자 지정 템플릿에서 자식 컨트롤의 텍스트 값이 손실됩니다. 양식 값이 이미 로드되었기 때문에 발생합니다.

적용 대상

추가 정보