As a component of item in list box

Hello

I have created a ListView with components list item as a label and a checkbox control.

When I check the box on a list item, I will not get an onTrigger event in the list.  Thus, there is no way to check if the box is checked or unchecked.  I don't need a single checkbox to be in a State of "verified" in both listview.

I tried to get the row of the box that is checked and call a function to browse the path to the index. Now I want to uncheck all of the boxes other than the one that is checked today.

CheckBox {
               id: checkBoxId
               horizontalAlignment: HorizontalAlignment.Right
               verticalAlignment: VerticalAlignment.Center
                onCheckedChanged: {
                 var rowNum = rootContainer.ListItem.indexPath;
                 count = articlesDataModel.size();
                  toggleCheckBox();
                                   }
          }

            function toggleCheckBox()
                    {
                      for (var i=0 ; i< count ; i++)
                       {
                        if(rootContainer.ListItem.indexPath[i]!= rowNum)
                         {
                          ????????
                          }

                         }

                      }

This is the code that I have tried. But I don't know how to get the control box here inside...

Could someone please look into this?

Thank you

SJ

Hello..

http://supportforums.BlackBerry.com/T5/Cascades-development/RadioButton-in-list-view-problem/TD-p/24...

This link helped me to solve this problem. Thank you

Tags: BlackBerry Developers

Similar Questions

  • AS3 - making an index for each item in list box

    Hi guys,.

    I'm puzzled. It could be something simple that I'm doing wrong.


    I have a table populated by XML based on the following inside the function:

    first_special.addItem({label: xmlMenuFile.item.headers[i],data: 
    xmlMenuFile.item.descriptions[i],data2: xmlMenuFile.item.hints[i]});
    

    The problem I have is trying to find a way for the "data2" will fill the text field 'hint_txt' on ROLL_OVER of the same name of items in the list.

    I tried to place an event listener in the function that populates the drop-down list box, but does not

    // this populates the combo box label and data with the Loaded XML File. This works
    function changeHandler(ev:Event):void
    {
         menuText_mc.heading1_txt.text = ev.currentTarget.selectedItem.label;
         menuText_mc.description1_txt.text = ev.currentTarget.selectedItem.data;
         heading1 = ev.currentTarget.selectedItem.label;
         includePrice1_mc.visible=true;
    
    
    // trying to figure out how to activate the 'hinting' function when you ROLL_OVER EACH ITEM in the 'first_special" combo box
    // and when rolling over it trace 'hello'. This DOES NOT WORK.
    first_special.addEventListener(MouseEvent.ROLL_OVER, hinting);
    }
    
    
    function hinting(e:MouseEvent):void{
    // Should trace "hello" everytime I Roll_OVER an item in the Combo Box.     
         trace("hello");
    }
    
    // calls the changeHandler function and works correctly
          first_special.addEventListener(Event.CHANGE, changeHandler);
    
    
    Any help with this would be great.
    
    Thanks
    

    For the features of indicators, I think you want to define...

    Import fl.events.ListEvent;

    function hinting(e:ListEvent):void {}
    var rowIdx:uint = e.rowIndex as uint;
    hint_txt. Text = .data2 first_special.getItemAt (IdxLigne);
    }

    first_special.addEventListener (ListEvent.ITEM_ROLL_OVER, hinting);

    What you react only to roll on the main component, not the elements, and this reversal starts to happen until you have selected an item since you buried the listener inside the change function.  Keep the headset out in the open.

  • Remove the space between the items in list box

    Hello

    I have a list box, I need to change the space between each item in the drop-down list.

    (ex)

    test

    Test1

    test2

    I need it to change the space between the test and vice versa test1.

    Kind regards

    Roman papail

    You must specify the list control rowHeight for example

                                  
    

    If this post answers your question or assistance, please mark it as such.

  • View creating Spry menu bar shows only preview of items in list boxes

    In Dreamweaver CS6, all of a sudden, my Spry stopped display in Design view menu bar, unless I click on Live. Live, it displays correctly with all styles. As in any browser displays correctly. Without Live in Design view, I see the box with no style and no text. However, if I click on the text, it will highlight the invisible text and it shows the location of the text in code view. This seems to be an option that I turned on accidentally or is it controlled by the properties?

    Thank you.  Menu Pop Magic 2 solved all the problems I had with Spry quickly and well.

  • How to change the items in a drop-down list box that is part of an array of clusters

    Hello

    In the attached vi, I have an array of clusters and each cluster contains two drop-down list boxes. How can I edit the items in the drop-down list box 1 for all elements in the array? (All elements of list box 1 has the same elements.)

    By way of illustration, I have also included the case of trivila, for example, edit the items in a separate drop-down list box that is is not part of an array of clusters (combo box 3). Please notify. Thank you.

    Peter

    Right click on the drop-down list box and select Create-> Node-> String() property. Place it on the block diagram. Change to write (right click) and then feed him an array of strings.

  • Change the number of items in the drop-down list box when running

    I'm trying to change the number of items in one of my boxes of comobo.

    I have been through the help and this forum and have the values to within the drop-down list box change very well, but in a scenario, I want to go to three options for 2. And according to other choices to 3.

    I guess I have to use a property node but I can't understand that one.

    You can use the method to reset to zero (using an invoke node) before setting the [Strings] (after setting the value by default an empty array) or create an Xcontrol (you can see examples of LabVIEW for xcontrol).

    Ben64

  • Can anyone help please if a drop-down list box with this dpdCategory.Items.Insert (0, "user")?

    can someone please help if a drop-down list box with this dpdCategory.Items.Insert (0, "user"); If I choose the user then after clicking the button, it will redirect to this page & also, others using if else statement

    Please ask this question in one of the Windows Apps development forums:

    http://social.msdn.Microsoft.com/forums/en-us/category/windowsapps

  • Impossible to select multiple items in the list box

    I use Acrobat 9.0 Standard.

    I added a list box in the PDF format and I want to give people the ability to select multiple items in the drop-down list. In properties, on the Options tab, I chose 'multiple choice '. But I am unable to make multiple selections despite this. It still only allows me to make a choice.

    Any ideas? Is there some other step I'm missing?

    I need help with this ASAP for my business - any suggestions are appreciated!

    Thank you

    It should do that if you hold down the SHIFT key.

  • cannot detect if it is has only 1 item in the drop-down list box?

    I have an array of strings to put them in the drop-down list box, a drop-down list box. I will select an item in the drop-down list box drop-down list and press the button 'delete '. It removes the item from the drop-down list box. but when I come to the last drop-down list box, im unable to remove offshore because it does not get pass this line...

    myEntries.selectedItem.label is myArray [i]

    Why do myEntries.selectedItem.label is not detected in the last element?

    Entries.addEventListener (Event.CHANGE, EntriesChange)

                   }

              }

    "" var str_entries:String = "";

    //set default

    function EntriesChange(e:Event):void {}

    for (var i = 0; i < myArray.length; i ++)

                   {

    { if (myEntries.selectedItem.label == {myArray [i].)}

    str_entries = myArray [i];

    trace ("str_entries =" + str_entries)

                        }

                   }

              }

    You can not able to delete the index 0th, the code below, did the trick:

    delbtn.addEventListener (MouseEvent.CLICK, delfn);
    function delfn(e:MouseEvent):void {}
    var str:String=String(Entries.selectedItem.label).toLowerCase();
    for (var i = 0; i)<>
    var str1:String=String(myArray[i]).toLowerCase();
    If (str == str1) {}
    Entries.removeItem (Entries.selectedItem);
    If (Entries.length == 0) Entries.removeAll ();
    str_entries = myArray [i];
    }
    }
    }

  • List box items, once again

    Need help with the items in drop-down list again.  I have a script that gets the text within the same form field values and displays the values as items in the drop-down list box.  It works perfectly; However, when I select an item in the list, the item does not stick/show when selected and the field is empty.

    Script is below:

    var l = this.getField ("T1T1 name");
    Value1 = this.getField("Name1").value;
    value2 = this.getField("Name2").value;
    value3 = this.getField("Name3").value;
    Value4 = this.getField("Name4").value;
    Value5 = this.getField("Name5").value;
    Value6 = this.getField("Name6").value;
    valeur7 = this.getField("Name7").value;
    value8 = this.getField("Name8").value;
    value9 = this.getField("Name9").value;
    value10 = this.getField("Name10").value;
    l.setItems (["", value1, value2, value3, value4, Value5, Value6, valeur7, value8, value9, value10,]);

    "T1T1 name" is the name of combo box

    When I take the first line of the script out, the element values stick/show when selected and I go to the next field, but they do not update when additional values are entered in the fields "name".

    Any help would be greatly appreciated.


    Thank you

    That's the problem. I suggest setting up a document level function that you call of each text field Validate event. the script would add only an element if the text field is not empty. The script will need to be changed a little. Post again if you get stuck.

  • Dynamically add a list box item

    Hello.

    I have a list box that is bound to a table, and now I need to add values to the list box.

    I can add a new item to the list of hard-coding a value, such as:

    arrayData.addItem ({'label': 'test2', 'data': '99'});

    It works very well. But the problem is that I do not know what will be the values,
    so I need a way ot add value dynamically using variables.

    I tried:

    var strLabel:String = 'Some Text';
    var strData:String = "99";
    var newItem:Object = "{"label":" "}" + strLabel + "', 'data':'" + strData + "'";}

    And then add it to the table:

    arrayData.addItem (newItem);

    But what appears in the list box is:

    {'label': 'Some Label', 'data': '99'}

    I tried all the variations I could think. What is the correct syntax to do this?

    Thank you








    The syntax is:

    var strLabel:String = 'Some Text';
    var strData:String = "99";
    var newItem:Object = {label: strLabel data: strData};
    arrayData.addItem (newItem);

  • get the index of a selected item in a drop-down list box

    Hello

    If I have a list of strings in a drop-down list box and the user selects one in the drop-down menu, how can I get the index?  I was able to explore the table for the selected channel, but it seems like duplication of effort to create a list and then go back and research it.

    Thank you

    Brendon

    It's easier to change control of the ring or Enum which gives the index as a default value, a drop-down list box gives a string that must be converted. But if you like really graphic and you want to use the drop-down list you can uncheck the "use strings as values" option and enter the index as numbers and then make a string to Decimal conversion.

    /Y

  • Display all items or all files in the drop-DOWN list BOX

    Hello

    How to show the total files available in the drop-down list box by scrolling.

    In my project, I have to store the Daq measurement values in file.

    Later, I need to plot a graph since the values of a specified file.

    For this I need to select a file from the number of files.

    Give an idea or a sample program.

    Kind regards

    Hari

    Hi hari,.

    I couldn't open your vi I use Labview 8.5.

    See vi attached with this post.

  • Select the item in the drop-down list box?

    Hello, I have a list box drop-down list box that contains numbers from 1 to 10. Normally, it will display "1" when the application starts, but how I put it in AS3 to show "3" instead?

    comboboxInstancename.selectedIndex = 2;

  • Items in drop-down list box

    I'll put up a form to fill out using adobe.  I'm trying to set a list box dropdown values/elements based on several fields in the form.  For example, the first part of the form will have a user list employee names.  I try to have the seized names appear as options in the drop-down list box.  Any suggestions would be greatly appreciated.

    This piece of code will get the values of the fields name1, name2, etc.. :

    Value1 = this.getField("Name1").value;

    value2 = this.getField("Name2").value;

    You can then use these variables (value1, value2, etc.) to set the values of the elements of list box.

Maybe you are looking for

  • How to install version 28 of 29?

    I want to go back to version 28. Interface version of 29 is hideous. I installed the add-on which supposedly makes it look like the 28 version, but it is not. I downloaded version 28. Everything I need to know is: uninstall 29 version before installi

  • HP 13-4007na Specter: Specter 360 won't come from hibernation

    Given that I've upgraded to windows 10 my unit won't come from hibernation. The battery is fully charged and the power switch lights up very occasionally. Apart from this, the device seems to be dead! Is there a procedure I use to wake up?

  • v3141TU. could not install SP35682 on Windows XP - SP3. Audio does not

    Hi all I just installed my v3141TU with Windows XP - SP3. and I have installed all the necessary additional drivers. I also installed the Microsoft UAA Audio (SP33566) from the HP website. and it's a successful installation. problem comes when I try

  • HP EliteBook 8560p: BIOS password problem

    Hello I started to work as an administrator, but a worker in front of me made the passwords to get into BIOS on three notebooks of EliteBook 8560p. I can start Windows normally, but if something goes wrong, I will not be able to enter the BIOS and mo

  • When I try to open the VAIO Care, a pop-up message is displayed

    When I try to open the VAIO Care, a pop-up message is displayed: "VAIOShell has stopped working. A problem caused the blocking of the program works correctly. Windows will close the program and notify you if a solution is available. Then the program