Syncfusion.XlsIO.Base
Example 


DropDownLines Property

Gets or sets the number of list lines displayed in the drop-down portion of a combo box.
Syntax
'Declaration
 
Property DropDownLines As Integer
'Usage
 
Dim instance As IComboBoxShape
Dim value As Integer
 
instance.DropDownLines = value
 
value = instance.DropDownLines
int DropDownLines {get; set;}
Example
The following code illustrates how to set DropDownLines property.
using Syncfusion.XlsIO;
            
class Program
{
    static void Main()
    {
        using (ExcelEngine excelEngine = new ExcelEngine())
        {
            //Create worksheet
            IApplication application = excelEngine.Excel;
            application.DefaultVersion = ExcelVersion.Excel2013;
            IWorkbook workbook = application.Workbooks.Create(1);
            IWorksheet worksheet = workbook.Worksheets[0];
            
            //Load data
            worksheet["J1"].Value = "1";
            worksheet["J2"].Value = "2";
            worksheet["J3"].Value = "3";
            worksheet["J4"].Value = "4";
            worksheet["J5"].Value = "5";
            
            //Add combobox
            IComboBoxShape combobox = worksheet.ComboBoxes.AddComboBox(2, 2, 20, 100);
            
            //Add combobox data
            combobox.ListFillRange = worksheet["J1:J5"];
            
            //Set selected index
            combobox.SelectedIndex = 1;
            
            //Set droplines
            combobox.DropDownLines = 2;
            
            //Save and dispose
            workbook.SaveAs("Shapes.xlsx");
            workbook.Close();
        }
    }
}
AssemblyVersion

Syncfusion.XlsIO.Base: 17.2460.0.34

See Also