本文整理匯總了VB.NET中System.Web.UI.Design.ConnectionStringEditor類的典型用法代碼示例。如果您正苦於以下問題:VB.NET ConnectionStringEditor類的具體用法?VB.NET ConnectionStringEditor怎麽用?VB.NET ConnectionStringEditor使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
在下文中一共展示了ConnectionStringEditor類的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的VB.NET代碼示例。
示例1: SqlDataSourceWithBackup
' Define a custom class derived from the SqlDataSource Web control.
Public Class SqlDataSourceWithBackup
Inherits SqlDataSource
Private _alternateConnectionString As String
' Define an alternate connection string, which could be used
' as a fallback value if the primary connection string fails.
' The EditorAttribute indicates the property can
' be edited at design-time with the ConnectionStringEditor class.
<DefaultValue(""), _
EditorAttribute(GetType(System.Web.UI.Design.ConnectionStringEditor), _
GetType(System.Drawing.Design.UITypeEditor)), _
Category("Data"), _
Description("The alternate connection string.")> _
Public Property AlternateConnectionString() As String
Get
Return _alternateConnectionString
End Get
Set(ByVal value As String)
_alternateConnectionString = value
End Set
End Property
End Class