Hi,
If a user types into the combobox normally it works fine, but it you copy/paste text into the combo box it does pick up the values on post back.
Is this a know issue?
I tried this fix
and it fires properly but the value of
this is similar to http://www.telerik.com/community/forums/aspnet-mvc/combobox/autocomplete-copy-and-paste-not-working-in-ie.aspx#1554552
thanks
Toby
If a user types into the combobox normally it works fine, but it you copy/paste text into the combo box it does pick up the values on post back.
Is this a know issue?
I tried this fix
var
$ = $telerik.$;
var
$T = Telerik.Web.UI;
var
$p = Telerik.Web.UI.RadComboBox.prototype;
var
onPaste = $p._onPaste;
$p._onPaste =
function
(e) {
text =
this
.get_text();
this
._updateFilterText =
true
;
};
and it fires properly but the value of
this
.get_text();
is empty if data has been pasted in there.
this is similar to http://www.telerik.com/community/forums/aspnet-mvc/combobox/autocomplete-copy-and-paste-not-working-in-ie.aspx#1554552
thanks
Toby
8 Answers, 1 is accepted
0
Hi Toby,
Thanks for your interest.
I tried the scenario that you describe and AutoComplete does not work when I paste text using right click of the mouse. It does work however, when I use Ctrl+V. Unfortunately I can not give you an answer now, because we will need more time to investigate the issue. I will write you back as soon as we figure out why this is happening.
Greetings,
Kate
the Telerik team
Thanks for your interest.
I tried the scenario that you describe and AutoComplete does not work when I paste text using right click of the mouse. It does work however, when I use Ctrl+V. Unfortunately I can not give you an answer now, because we will need more time to investigate the issue. I will write you back as soon as we figure out why this is happening.
Greetings,
Kate
the Telerik team
Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!
0
Hi Toby,
While revisiting the case we were able to observe different behaviors that were inconsistent with your description of the issue. In order to start working on it we will need to reproduce it consistently. Can you paste here the definition of the RadComboBox with which you observed the issue as well as specify in which browsers you observed it?
Regards,
Simon
the Telerik team
While revisiting the case we were able to observe different behaviors that were inconsistent with your description of the issue. In order to start working on it we will need to reproduce it consistently. Can you paste here the definition of the RadComboBox with which you observed the issue as well as specify in which browsers you observed it?
Regards,
Simon
the Telerik team
0

Barbara
Top achievements
Rank 1
answered on 18 Mar 2013, 09:19 PM
Have there been any updates on this?
We are experiencing this issue where we have a RadComboBox and a required field validator on the page. Ctrl-V works and triggers the validation but right-click and paste does not.
Thanks,
We are experiencing this issue where we have a RadComboBox and a required field validator on the page. Ctrl-V works and triggers the validation but right-click and paste does not.
Thanks,
0
Hi Barbara,
Current build 2013.1.220 supports right-click and paste with latest versions for all browsers except IE. For older versions and IE try to add the following javascript:
This code attaches event listener for OnInput and OnPaste events of the combo's input element and force combo to request items.
Regards,
Hristo Valyavicharski
the Telerik team
Current build 2013.1.220 supports right-click and paste with latest versions for all browsers except IE. For older versions and IE try to add the following javascript:
function
pageLoad() {
var
combo = $find(
'RadComboBox1'
);
$(
'#RadComboBox1_Input'
).live(
'input paste'
,
function
(e) {
//Get pasted value
var
pastedValue = $(
this
).val();
//Request items
combo.requestItems(pastedValue,
false
);
});
}
Regards,
Hristo Valyavicharski
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0

Daniel
Top achievements
Rank 1
answered on 08 May 2013, 10:51 AM
Hello,
I had the same problem in one of my projects and fixed it that way:
I first set the EnableAutmoaticLoadOnDemand-property to false.
Than I implemented a javascriptfunction at the OnKeyUp-event that fires the requestItems-method.
With this fix there's only one event that triggers the requestItems-method.
The problem pasting from clipboard with right-click isn't affected by that fix.
I think that the problem occurs because the internal function, that is enabled by the EnableAutmoaticLoadOnDemand-property, uses the OnTextChanged-event. This event won't be fired when data is pasted or the delete key is pressed for example.
Regards
Daniel
I had the same problem in one of my projects and fixed it that way:
I first set the EnableAutmoaticLoadOnDemand-property to false.
<
telerik:RadComboBox
ID
=
"ComboBox1"
runat
=
"server"
AllowCustomText
=
"false"
Filter
=
"Contains"
MarkFirstMatch
=
"true"
ShowToggleImage
=
"false"
OpenDropDownOnLoad
=
"false"
OnItemsRequested
=
"ComboBox1_ItemsRequested"
EnableAutomaticLoadOnDemand
=
"false"
OnKeyUp
=
"ComboBox1_KeyUp()"
>
</
telerik:RadComboBox
>
Than I implemented a javascriptfunction at the OnKeyUp-event that fires the requestItems-method.
function
ComboBox1_KeyUp() {
var
combo = $find(
"<%=ComboBox1.ClientID %>"
);
var
comboText = combo.get_text();
combo.requestItems(comboText,
false
);
}
With this fix there's only one event that triggers the requestItems-method.
The problem pasting from clipboard with right-click isn't affected by that fix.
I think that the problem occurs because the internal function, that is enabled by the EnableAutmoaticLoadOnDemand-property, uses the OnTextChanged-event. This event won't be fired when data is pasted or the delete key is pressed for example.
Regards
Daniel
0
Hi Daniel,
At the moment you set AllowCustomText to false and Filter equal to Contains which are mutually exclusive.
This issue is resolved and the fix will be included in the upcoming service release. Until the fix release you could try to use the following workaround:
Kind regards,
Hristo Valyavicharski
the Telerik team
At the moment you set AllowCustomText to false and Filter equal to Contains which are mutually exclusive.
This issue is resolved and the fix will be included in the upcoming service release. Until the fix release you could try to use the following workaround:
<script type=
"text/javascript"
>
function
ComboBox1_KeyUp() {
var
combo = $find(
"<%=RadComboBox1.ClientID %>"
);
var
comboText = combo.get_text();
combo.requestItems(comboText,
false
);
}
function
OnClientBlur(sender, args) {
var
comboText = sender.get_text();
sender.requestItems(comboText,
false
);
}
</script>
<
telerik:RadComboBox
ID
=
"RadComboBox1"
runat
=
"server"
AllowCustomText
=
"false"
Filter
=
"Contains"
MarkFirstMatch
=
"true"
ShowToggleImage
=
"false"
OpenDropDownOnLoad
=
"false"
OnClientBlur
=
"OnClientBlur"
OnItemsRequested
=
"RadComboBox1_ItemsRequested"
EnableAutomaticLoadOnDemand
=
"false"
OnKeyUp
=
"ComboBox1_KeyUp()"
>
</
telerik:RadComboBox
>
Kind regards,
Hristo Valyavicharski
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0

Richard
Top achievements
Rank 2
answered on 08 Aug 2013, 04:05 PM
Our page has 10 controls. I wrote a simple foreach loop to iterate through the controls (comboValue0 - comboValue9). I am getting "Object not found" when I try to run your code specified.
This is the line that is failing.
Any help would be appreciated.
This is the line that is failing.
$(
'#ctl00_ContentPlaceHolder2_RadPanelBar1_i0_SearchControl1_comboValue'
+ i +
'_Input'
).live
Any help would be appreciated.
function
pageLoad() {
for
(
var
i = 0; i <= 9; i++) {
debugger;
var
combo = $find(
'ctl00_ContentPlaceHolder2_RadPanelBar1_i0_SearchControl1_comboValue'
+ i);
$(
'#ctl00_ContentPlaceHolder2_RadPanelBar1_i0_SearchControl1_comboValue'
+ i +
'_Input'
).live(
'input paste'
,
function
(e) {
//Get pasted value
var
pastedValue = $(
this
).val();
//Request items
combo.requestItems(pastedValue,
false
);
});
}
0
Hi Richard,
jQuery live() was deprecated. Try to replace your code with the following:
it should be applied for all combos.
Regards,
Hristo Valyavicharski
Telerik
jQuery live() was deprecated. Try to replace your code with the following:
Copy Code
function
pageLoad() {
$(
'.rcbInput, .radPreventDecorate'
).bind(
'input paste'
,
function
() {
var
comboInput = $(
this
);
setTimeout(
function
() {
console.log(comboInput.parents(
'div:eq(0)'
).attr(
'id'
));
combo = $find(comboInput.parents(
'div:eq(0)'
).attr(
'id'
));
console.log(combo._inputDomElement.value);
combo.requestItems(combo._inputDomElement.value,
false
);
}, 1);
});
}
it should be applied for all combos.
Regards,
Hristo Valyavicharski
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.