Version

DropDownWidth Property

Determines the width of the dropdown at runtime.
Syntax
'Declaration
 
Public Property DropDownWidth As Integer
public int DropDownWidth {get; set;}
Remarks

The default value is -1. This means that the dropdown will automatically size based on the widths of the columns it contains. It will limit itself to the size of the screen.

A setting of 0 will cause the dropdown to auto-size itself to the width of the edit portion. In the case of the UltraCombo control, this is the width of the control. In the case of the UltraDropDown control, this will be the size of the editor in the column.

A setting of -2 will behave very much like -1. It will attempt to size the dropdown to the required width of the columns it contains. But, in addition, it will enforce a minimum width equal the width of the control.

A value greater than 0 will force the dropdown to be that number of pixels wide.

Example
Following code sets the widths of the drop downs of an UltraDropDown and an UltraCombo.

Imports Infragistics.Shared
Imports Infragistics.Win
Imports Infragistics.Win.UltraWinGrid

  Private Sub Button4_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button4.Click

      ' By default, the width of the drop down is calculated based on the columns and
      ' their widths so all the columns are visible. However you may want to limit the
      ' width or have a larger width than what's required to fit the columns. In such
      ' cases, you can control the width of the drop down of an UltraDropDown as well as
      ' an UltraCombo by setting the DropDownWidth property to a desired value.
      Me.ultraDropDown1.DropDownWidth = 200
      Me.ultraCombo1.DropDownWidth = 200

  End Sub
using Infragistics.Shared;
using Infragistics.Win;
using Infragistics.Win.UltraWinGrid;
using System.Diagnostics;

private void button4_Click(object sender, System.EventArgs e)
{

	// By default, the width of the drop down is calculated based on the columns and
	// their widths so all the columns are visible. However you may want to limit the
	// width or have a larger width than what's required to fit the columns. In such
	// cases, you can control the width of the drop down of an UltraDropDown as well as
	// an UltraCombo by setting the DropDownWidth property to a desired value.
	this.ultraDropDown1.DropDownWidth = 200;
	this.ultraCombo1.DropDownWidth    = 200;

}
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also