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

Trying to compare sender.get_id

1 Answer 142 Views
Grid
This is a migrated thread and some comments may be shown as answers.
mSchmidt
Top achievements
Rank 1
mSchmidt asked on 20 Oct 2008, 07:59 PM

 

Why doesnt this work ?
The following script is within an ItemTemplate hence the Container.FindControl..


if
(sender.get_id == $find('<%# Container.FindControl("RadComboBox1").ClientID %>').get_id ) {
j = 0;
}
else if (sender.get_id == $find('<%# Container.FindControl("RadComboBox2").ClientID %>').get_id) {
j = 1;
}
else if (sender.get_id == $find('<%# Container.FindControl("RadComboBox3").ClientID %>').get_id) {
j = 2;
}

 

1 Answer, 1 is accepted

Sort by
0
Accepted
Vladimir
Top achievements
Rank 1
answered on 21 Oct 2008, 04:13 AM
Generally get_id() is a method and if you want to compare by id you will need to execute this method:

if (sender.get_id() == $find('<%# Container.FindControl("RadComboBox1").ClientID %>').get_id() ) {
j = 0;
}

Tags
Grid
Asked by
mSchmidt
Top achievements
Rank 1
Answers by
Vladimir
Top achievements
Rank 1
Share this question
or