Inherited DropDownList Designer problem

Discussion in 'ASP .Net Building Controls' started by Ron Vecchi, Sep 13, 2003.

  1. Ron Vecchi

    Ron Vecchi Guest

    I have an inherited DropDownList custom control that in the DataBind()
    method I add a bunch pre determined list items that contain the various
    Country names and Abbreviations.

    There are four options of displaying these Items that is based on enum :
    ------------------------------------------------------------------------
    AbbreviatesItemViewMode
    NamesOnly - Adds the ListItems with the Country name as both the value
    and text
    AbbreviationsOnly - Adds the ListItems with the 3character Abbrevication
    as both the value and text
    NameValues - Adds the ListItems with the Country name as the value and
    the ABBR as the text
    AbbreviationValues - Adds the ListItems with the ABBR as the value and
    name as the text.

    [Default value is AbbreviationsOnly.]
    -------------------------------------------------------------------------

    Everything works great!...except I'm trying to get it to work with the
    designer. new territory for me.

    When I drag the control to the form from the toolbox the default value is
    set(correct) and the ListItems are displayed correctly when I switch to
    HtmlView.
    But if I go to the properties window and change the AbbreviatesItemViewMode
    property the list items in the HTML view are not changed.

    Any Sugesstions?


    Thanks,
    Ron
     
    Ron Vecchi, Sep 13, 2003
    #1
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.