共用方式為


PersistenceModeAttribute.Mode 屬性

定義

取得 PersistenceMode 列舉型別的目前值。

public:
 property System::Web::UI::PersistenceMode Mode { System::Web::UI::PersistenceMode get(); };
public System.Web.UI.PersistenceMode Mode { get; }
member this.Mode : System.Web.UI.PersistenceMode
Public ReadOnly Property Mode As PersistenceMode

屬性值

PersistenceMode,表示列舉型別的目前值。 這個值可以是 AttributeInnerPropertyInnerDefaultPropertyEncodedInnerDefaultProperty。 預設為 Attribute

範例

[PersistenceMode(PersistenceMode.InnerProperty),
TemplateContainer(typeof(TemplateItem))]
public ITemplate MessageTemplate {
   get {
      return _messageTemplate;
   }
   set {
      _messageTemplate = value;
   }
}

<PersistenceMode(PersistenceMode.InnerProperty), TemplateContainer(GetType(TemplateItem))> Public Property MessageTemplate() As ITemplate
   Get
      Return _messageTemplate
   End Get
   Set(ByVal Value As ITemplate)
      _messageTemplate = Value
   End Set
End Property

適用於

另請參閱