더북(TheBook)

3. FrmPlaceHolder.aspx 페이지에 다음과 같이 입력한다.

▼  FrmPlaceHolder.aspx

<%@ Page Language="C#" AutoEventWireup="true"
  CodeBehind="FrmPlaceHolder.aspx.cs" Inherits="DevStandardControl.FrmPlaceHolder" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  <title>플레이스홀더 컨트롤</title>
</head>
<body>
  <form id="form1" runat="server">
      <div>
          <asp:PlaceHolder ID="ctlPlaceHolder" runat="server"></asp:PlaceHolder>
          <hr />
          <asp:Label ID="lblDisplay" runat="server"></asp:Label>
      </div>
  </form>
</body>
</html>

 

웹 폼에 등록된 컨트롤의 주요 속성은 다음과 같다.

컨트롤

속성

PlaceHolder

ID

ctlPlaceHolder

LinkButton

ID

btnGetText

Text

생성된 버튼의 텍스트 가져오기

Label

ID

lblDisplay

Text

(빈 문자열)