本文整理汇总了C#中System.Web.UI.WebControls.ListControl.BindToDefinedType方法的典型用法代码示例。如果您正苦于以下问题:C# ListControl.BindToDefinedType方法的具体用法?C# ListControl.BindToDefinedType怎么用?C# ListControl.BindToDefinedType使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Web.UI.WebControls.ListControl
的用法示例。
在下文中一共展示了ListControl.BindToDefinedType方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: BindDefinedTypeDropdown
/// <summary>
/// Binds the defined type dropdown.
/// </summary>
/// <param name="ListControl">The list control.</param>
/// <param name="definedTypeGuid">The defined type GUID.</param>
/// <param name="userPreferenceKey">The user preference key.</param>
private void BindDefinedTypeDropdown( ListControl listControl, Guid definedTypeGuid, string userPreferenceKey )
{
listControl.BindToDefinedType( DefinedTypeCache.Read( definedTypeGuid ) );
listControl.Items.Insert( 0, new ListItem( string.Empty, string.Empty ) );
if ( !string.IsNullOrWhiteSpace( gfTransactions.GetUserPreference( userPreferenceKey ) ) )
{
listControl.SelectedValue = gfTransactions.GetUserPreference( userPreferenceKey );
}
}
示例2: BindListToDefinedType
/// <summary>
/// Binds the type of the list to defined.
/// </summary>
/// <param name="listControl">The list control.</param>
/// <param name="definedTypeGuid">The defined type GUID.</param>
/// <param name="insertBlankOption">if set to <c>true</c> [insert blank option].</param>
protected void BindListToDefinedType( ListControl listControl, string definedTypeGuid, bool insertBlankOption = false )
{
var definedType = DefinedTypeCache.Read( new Guid( definedTypeGuid ) );
listControl.BindToDefinedType( definedType, insertBlankOption );
}
示例3: BindDefinedTypeDropdown
/// <summary>
/// Binds the defined type dropdown.
/// </summary>
/// <param name="ListControl">The list control.</param>
/// <param name="definedTypeGuid">The defined type GUID.</param>
/// <param name="userPreferenceKey">The user preference key.</param>
private void BindDefinedTypeDropdown( ListControl listControl, Guid definedTypeGuid, string userPreferenceKey )
{
listControl.BindToDefinedType( DefinedTypeCache.Read( definedTypeGuid ) );
listControl.SelectedValue = !string.IsNullOrWhiteSpace( gfBatchFilter.GetUserPreference( userPreferenceKey ) ) ?
listControl.SelectedValue = gfBatchFilter.GetUserPreference( userPreferenceKey ) : null;
}
示例4: BindDefinedTypeDropdown
/// <summary>
/// Binds the defined type dropdown.
/// </summary>
/// <param name="ListControl">The list control.</param>
/// <param name="definedTypeGuid">The defined type GUID.</param>
/// <param name="userPreferenceKey">The user preference key.</param>
private void BindDefinedTypeDropdown( ListControl ListControl, Guid definedTypeGuid, string userPreferenceKey )
{
ListControl.BindToDefinedType( DefinedTypeCache.Read( definedTypeGuid ) );
//ListControl.Items.Insert( 0, new ListItem( All.Text, All.Id.ToString() ) );
ListControl.SelectedValue = !string.IsNullOrWhiteSpace( rFBFilter.GetUserPreference( userPreferenceKey ) ) ?
ListControl.SelectedValue = rFBFilter.GetUserPreference( userPreferenceKey ) : null;
}
示例5: BindDefinedTypeDropdown
/// <summary>
/// Binds the defined type dropdown.
/// </summary>
/// <param name="ListControl">The list control.</param>
/// <param name="definedTypeGuid">The defined type GUID.</param>
/// <param name="userPreferenceKey">The user preference key.</param>
private void BindDefinedTypeDropdown( ListControl listControl, Guid definedTypeGuid, string userPreferenceKey )
{
listControl.BindToDefinedType( DefinedTypeCache.Read( definedTypeGuid ) );
}