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

Intermittent Error on Production with elerik.Web.UI.RadComboBox.

6 Answers 26 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Krishnat
Top achievements
Rank 1
Krishnat asked on 08 Jan 2015, 07:49 AM
Exception type: TargetInvocationException 
    Exception message: Exception has been thrown by the target of an invocation.
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
   at System.Web.Script.Serialization.JavaScriptSerializer.SerializeCustomObject(Object o, StringBuilder sb, Int32 depth, Hashtable objectsInUse, SerializationFormat serializationFormat)
   at System.Web.Script.Serialization.JavaScriptSerializer.SerializeValueInternal(Object o, StringBuilder sb, Int32 depth, Hashtable objectsInUse, SerializationFormat serializationFormat, MemberInfo currentMember)
   at System.Web.Script.Serialization.JavaScriptSerializer.SerializeValue(Object o, StringBuilder sb, Int32 depth, Hashtable objectsInUse, SerializationFormat serializationFormat, MemberInfo currentMember)
   at System.Web.Script.Serialization.JavaScriptSerializer.Serialize(Object obj, StringBuilder output, SerializationFormat serializationFormat)
   at System.Web.Script.Serialization.JavaScriptSerializer.Serialize(Object obj, SerializationFormat serializationFormat)
   at Telerik.Web.UI.RadComboBox.DescribeComponent(IScriptDescriptor descriptor)
   at Telerik.Web.UI.ScriptRegistrar.GetScriptDescriptors(Control control)
   at Telerik.Web.UI.RadDataBoundControl.GetScriptDescriptors()
   at System.Web.UI.ScriptControlManager.RegisterScriptDescriptors(IScriptControl scriptControl)
   at Telerik.Web.UI.RadDataBoundControl.Render(HtmlTextWriter writer)
   at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter)
   at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)
   at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter)
   at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)
   at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter)
   at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)
   at System.Web.UI.HtmlControls.HtmlForm.RenderChildren(HtmlTextWriter writer)
   at System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer)
   at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter)
   at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)
   at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter)
   at System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)
   at System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter)
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

Value cannot be null.
Parameter name: registration

6 Answers, 1 is accepted

Sort by
0
Nencho
Telerik team
answered on 12 Jan 2015, 03:39 PM
Hello Krishnat,

Please provide more information about the scenario, in which the control is used and how it is populated. It would be helpful if you could demonstrate us the implementation of the RadCombobox that you use at your end.

Regards,
Nencho
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Krishnat
Top achievements
Rank 1
answered on 13 Jan 2015, 12:52 PM
<div class="block search clicker">
<telerik:RadComboBox ID="rcb1" runat="server" OnItemsRequested="rcb1_ItemsRequested" ExpandDelay="0" ItemsPerRequest="5" AllowCustomText="true" EnableLoadOnDemand="true" ShowMoreResultsBox="true" EmptyMessage="Full text search" />
<asp:LinkButton ID="b1" runat="server" OnClick="b1_Click" CssClass="btn btn-primary enterAction" rel="tooltip" ToolTip="Search" ClientIDMode="AutoID"><i class="icon-search"></i></asp:LinkButton>
</div>


Code Behind :-
protected void rcb1_ItemsRequested(object sender, RadComboBoxItemsRequestedEventArgs e)
{
if (e.Text == null)
{
return;
}

if (e.Text.Length < NumberOfCharactersBeforeAutoComplete)
{
return;
}

ISearchExecutor searchExecutor = GetInstance<ISearchExecutor>();
IList<string> suggestions = searchExecutor.ExecuteSuggestionsQuery(e.Text);
if (suggestions.Count == 0)
{
e.EndOfItems = true;
return;
}

RadComboBox rcb = (RadComboBox)sender;
IList<string> items = new List<string>(suggestions.Skip(e.NumberOfItems).Take(rcb.ItemsPerRequest));
if (items.Count == 0)
{
e.EndOfItems = true;
return;
}

foreach (string item in items)
{
RadComboBoxItem crbItem = new RadComboBoxItem(item);
rcb.Items.Add(crbItem);
}
}

protected void b1_Click(object sender, EventArgs e)
{
List<string> fullTextSearchEntries = new List<string>();
if (!string.IsNullOrEmpty(Request.QueryString["texts"]))
{
foreach (string s in Request.QueryString["texts"].FromBase64().Split('\0'))
{
if (!fullTextSearchEntries.Contains(s))
{
fullTextSearchEntries.Add(s);
}
}
}
if (!string.IsNullOrEmpty(rcb1.Text))
{
if (!fullTextSearchEntries.Contains(rcb1.Text))
{
fullTextSearchEntries.Add(rcb1.Text);
}
}

QueryStringBuilder queryStringBuilder = new QueryStringBuilder(new Uri(Page.BaseUrl, "Pages/Search.aspx"), new string[] { "culture", "path" });
queryStringBuilder.Set(Request.QueryString);
queryStringBuilder.Set("ii", null);
queryStringBuilder.Set("texts", string.Join("\0", fullTextSearchEntries.ToArray()).ToBase64());
Response.Redirect(queryStringBuilder.ToString(), true);
}


0
Nencho
Telerik team
answered on 16 Jan 2015, 08:14 AM
Hello Krishnat,

I tried to replicate the described issue but several class references are missing in the provided code snippet. If you could provide us with those declaration and elaborate a bit more on the scenario that you have implemented at your end it would be very helpful.

In addition, specify at what point encountered issue arises. Do you experience the exception, when the RadComboBox expands (when ItemsRequested event is triggered), or when the Response.Redirect is executed at the button click event handler?

Regards,
Nencho
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Krishnat
Top achievements
Rank 1
answered on 28 Aug 2015, 03:15 PM

We are getting this error during the load test when multiple users access the application. The connection to webresource.axd file get broken untill we restart the application pool.

 

Please find the attached file for more information. Thanks.

0
Krishnat
Top achievements
Rank 1
answered on 31 Aug 2015, 08:48 AM
Hi, Any updates on this. Thanks.
0
Krishnat
Top achievements
Rank 1
answered on 31 Aug 2015, 02:04 PM
Hi, Any updates?
Tags
ComboBox
Asked by
Krishnat
Top achievements
Rank 1
Answers by
Nencho
Telerik team
Krishnat
Top achievements
Rank 1
Share this question
or