<DefaultProperty("Text"), ToolboxData("<{0}:WebCustomControl1 runat=server></{0}:WebCustomControl1>")> Public Class WebCustomControl1
Inherits System.Web.UI.WebControls.WebControl
Dim _text As String
<Bindable(True), Category("Appearance"), DefaultValue("")> Property [Text]() As String
Get
Return _text
End Get
Set(ByVal Value As String)
_text = Value
End Set
End Property
Protected Overrides Sub Render(ByVal output As System.Web.UI.HtmlTextWriter)
If Site Is Nothing Then
output.Write("不在设计器中")
Else
output.Write("在设计器中")
End If
End Sub
ms-help://MS.VSCC.2003/MS.MSDNQTR.2003FEB.2052/cpref/html/frlrfSystemComponentModelISiteClassDesignModeTopic.htm
.DesignMode 属性 [Visual Basic]请参见
ISite 接口 | ISite 成员 | System.ComponentModel 命名空间 | ISite 成员(Visual J# 语法) | C++ 托管扩展编程
要求
平台: Windows 98, Windows NT 4.0, Windows ME, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 系列, .NET Framework 精简版 - Windows CE .NET
语言
C#
C++
JScript
Visual Basic
全部显示
确定组件在由类实现时是否处于设计模式。
[Visual Basic]
ReadOnly Property DesignMode As Boolean