Search Results for

    Show / Hide Table of Contents

    TExcelFile.AddComboBox Method

    Adds a ComboBox to the active sheet.

    Remarks

    Excel supports 2 types of comboboxes: ActiveX and internal (In Excel you would add them from the "ActiveX" and "Forms" toolbars respectively) The comboboxes added by this method are of type internal. ActiveX comboboxes are not supported.

    Syntax

    Unit: FlexCel.Core

    function TExcelFile.AddComboBox(const anchor: TClientAnchor; const name: string; const linkedCell: TCellAddress; const inputRange: TCellAddressRange; const selectedItem: Integer): Integer; virtual; abstract;

    Parameters

    <-> Parameter Type Description
    const anchor TClientAnchor Position for the combobox.
    const name string Name of the inserted combobox.
    const linkedCell TCellAddress Cell that will be linked to the combobox. Set this to null to not link any cell.
    const inputRange TCellAddressRange Range of cells with the values that the combobox will display.
    const selectedItem Integer Item that will be selected, starting at 1. 0 means no selected item.

    Returns

    Object Index of the inserted combobox (1 based).

    See also

    • TExcelFile
    In This Article
    Back to top FlexCel Studio for VCL and FireMonkey v7.24
    © 2002 - 2025 tmssoftware.com