This is a migrated thread and some comments may be shown as answers.

Checkbox added to listbox

2 Answers 68 Views
Calendar
This is a migrated thread and some comments may be shown as answers.
Anmol Maitra
Top achievements
Rank 1
Anmol Maitra asked on 31 Aug 2009, 09:16 PM
I have two listboxes (source and destination listbox)

I added server side code to have the checkbox checked in the destination listbox depending on a database value. Here is the code to do that. But when I transfer one of the items back to the source listbox, all the checkboxes get unchecked in the destination listbox. Can you tell me why this is happening?

        protected void RadListBoxDestination_Inserted(object sender, RadListBoxEventArgs e)
        {
            string selectedQlfr = QlfrDropDown.SelectedValue;
            BtodGenericGrid GridSchema = BtodGenericGrid.CreateInstance(selectedQlfr, "Default", "-1");
            for (int i = 0; i < e.Items.Count; i++)
            {
                string colName = e.Items[i].Text.ToString().ToUpper();
                for (int x = 0; x <= GridSchema.ColumnNamesWithAliasSplit.Length - 1; x++)
                {
                    if (colName == GridSchema.ColumnNamesWithAliasSplit[x].ToUpper())
                    {
                        if (GridSchema.ColumnVisibleSplit[x].ToString() == "1")
                        {
                            e.Items[i].Checked = true;
                        }
                        break;
                    }
                }
             //   e.Items[i].Checked = true;
            }

        }

2 Answers, 1 is accepted

Sort by
0
SamJ
Top achievements
Rank 1
answered on 03 Sep 2009, 06:26 AM
HI,

I think you posted your question in the wrong forum. I am not sure if the described issue have something in common with RadCalendar.
Is that right?

SamJ
0
Simon
Telerik team
answered on 03 Sep 2009, 10:18 AM
Hello Anmol,

I was unable to reproduce the issue you are describing. Please see the attached page for reference.

Am I missing something?

Best wishes,
Simon
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
Calendar
Asked by
Anmol Maitra
Top achievements
Rank 1
Answers by
SamJ
Top achievements
Rank 1
Simon
Telerik team
Share this question
or