Ext.net Combox Selected item.value in Ext2.0

  1. #1

    Ext.net Combox Selected item.value in Ext2.0

    i am using Ext.net 2.0 DLL's and want have a comboBox on my page.
    I am using a store to bind values to the combobox frm database and its successfully done.
    But the problem is that after binding it,i want it to display that record whose Id I am passing it like this.
    ComboBox1.selecteditem.value=1;

    This is not woriking in Ext.Net 2.0
    This is working perfect in ext 1.2 version

    Please help me ASAP..
    Thanks in Advance
  2. #2
    Use SelectedItems collection
  3. #3
    Quote Originally Posted by Vladimir View Post
    Use SelectedItems collection
    -----Code Line
    foreach (var Getdata in GetList)
                {
                    TxtDescription.Text = Getdata.Description;
                    TxtNotes.Text = Getdata.Notes;
                  
                    DDLCountry.SelectedItem.Value = Getdata.FkCountry.ToString();
                    DDLStatus.SelectedItem.Value = Getdata.Status.ToString();
                }
    ---Ends

    Can u please Explain me here how to do it becuase i am simply using like this.
    Last edited by geoffrey.mcgill; Aug 07, 2012 at 3:17 PM. Reason: please use [CODE] tags
  4. #4
    SelectedItems (not SelectedItem)
    See https://examples2.ext.net/#/Form/Com...Items_Actions/
  5. #5
    Quote Originally Posted by Vladimir View Post
    SelectedItems (not SelectedItem)
    See https://examples2.ext.net/#/Form/Com...Items_Actions/
    Thank u brother...It worked...
    PEACE :)
  6. #6
    Quote Originally Posted by OSSAGHO View Post
    Thank u brother...It worked...
    PEACE :)

    Actually i have to make a lot of changes in my Code for that.
    Can't we use the Ext.Net 1.2 methods like ComboBox1,selecteditem.value or ComboBox1.selecteditem.text..
    ???????????
    becuase i have one please select option in my comboBox List and it has one list item as Please Select,
    So when the user just finished the work on that screen,i want that comboBox Control to go back to Please Select item
    In 1.2 I was doing it by simply writing the above Line.
    Please help me out,.

Similar Threads

  1. Replies: 0
    Last Post: Feb 23, 2012, 12:42 PM
  2. [CLOSED] Always selected Item is nothing for combobox as menu item
    By rnachman in forum 1.x Legacy Premium Help
    Replies: 2
    Last Post: Sep 04, 2011, 4:51 PM
  3. Postback when an item is selected
    By lazycoder in forum 1.x Help
    Replies: 0
    Last Post: Jun 15, 2009, 9:13 AM
  4. Get Combobox Selected item
    By yarlenvas in forum 1.x Help
    Replies: 3
    Last Post: Mar 08, 2009, 2:04 PM
  5. Get ComboBox Selected Item
    By speedstepmem3 in forum 1.x Legacy Premium Help
    Replies: 2
    Last Post: Nov 18, 2008, 9:50 AM

Tags for this Thread

Posting Permissions