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

Problem after postback when tabs are created at client-side

7 Answers 184 Views
TabStrip
This is a migrated thread and some comments may be shown as answers.
giovaneBrazil
Top achievements
Rank 1
giovaneBrazil asked on 06 Oct 2010, 06:55 PM
Dear Support , please advice ...
im creating a page like this  telerik demo :
http://demos.telerik.com/aspnet-ajax/window/examples/radwindowandmdi/defaultcs.aspx
using the same javascript code , even whit the
tabStrip.trackChanges();
and
tabStrip.commitChanges();
however i put a .net dropdownlist  whith a postback event ( to set a profile that i whant to get in new windows) , and everytime the dropdownlist do the postback AND i created a new tab ( javascript ) , i got an .net error OBJECT REFERENCE NOT SET ....

COULD SOME ONE PLEASE HELP ME ? what more should i so ?

thnks !

NullReferenceException: Referência de objeto não definida para uma instância de um objeto.]
   Telerik.Web.UI.NavigationItem.LoadFromDictionary(IDictionary`2 dictionary) +104
   Telerik.Web.UI.RadTab.LoadFromDictionary(IDictionary`2 dictionary) +19
   Telerik.Web.UI.ClientStateLogPlayer`1.Insert(ClientStateLogEntry entry, ControlItemCollection items, Int32 index) +105
   Telerik.Web.UI.ClientStateLogPlayer`1.Play(ClientStateLogEntry entry) +219
   Telerik.Web.UI.ClientStateLogPlayer`1.Play(IEnumerable`1 clientStateLogEntry) +135
   Telerik.Web.UI.RadTabStrip.LoadLogEntries(TabStripClientState state) +34
   Telerik.Web.UI.RadTabStrip.LoadClientState(TabStripClientState state) +40
   Telerik.Web.UI.RadTabStrip.LoadPostData(String postDataKey, NameValueCollection postCollection) +166
   Telerik.Web.UI.RadDataBoundControl.System.Web.UI.IPostBackDataHandler.LoadPostData(String postDataKey, NameValueCollection postCollection) +13
   System.Web.UI.Page.ProcessPostData(NameValueCollection postData, Boolean fBeforeLoad) +690
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1743

 

7 Answers, 1 is accepted

Sort by
0
Helen
Telerik team
answered on 11 Oct 2010, 11:32 AM
Hello,

Could you please open a formal support ticket and send us your page to examine it locally?
Otherwise we cannot be sure where the problem might be.

Greetings,
Helen
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Marek
Top achievements
Rank 1
answered on 03 Feb 2011, 04:25 PM
Any solution found to this problem mentioned above ??? I have the same problem:

Error Message:Object reference not set to an instance of an object.
Stack Trace:   at Telerik.Web.UI.NavigationItem.LoadFromDictionary(IDictionary`2 dictionary)
   at Telerik.Web.UI.RadTab.LoadFromDictionary(IDictionary`2 dictionary)
   at Telerik.Web.UI.ClientStateLogPlayer`1.Insert(ClientStateLogEntry entry, ControlItemCollection items, Int32 index)
   at Telerik.Web.UI.ClientStateLogPlayer`1.Play(ClientStateLogEntry entry)
   at Telerik.Web.UI.ClientStateLogPlayer`1.Play(IEnumerable`1 clientStateLogEntry)
   at Telerik.Web.UI.RadTabStrip.LoadLogEntries(TabStripClientState state)
   at Telerik.Web.UI.RadTabStrip.LoadClientState(TabStripClientState state)
   at Telerik.Web.UI.RadTabStrip.LoadPostData(String postDataKey, NameValueCollection postCollection)
   at Telerik.Web.UI.RadDataBoundControl.System.Web.UI.IPostBackDataHandler.LoadPostData(String postDataKey, NameValueCollection postCollection)
   at System.Web.UI.Page.ProcessPostData(NameValueCollection postData, Boolean fBeforeLoad)
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

It occurs when TabStrip is instantiated and some elements are added on it then I do postback by asp LinkButton on my page then error occurs.
I am using Telerik.Web.UI in version 2010.3.1317.35. I can not find any ticket about this problem.

Please help
0
Helen
Telerik team
answered on 04 Feb 2011, 01:58 PM
Hi,

We tried to reproduce the problem locally, but without much success. Please refer to our test files for details.
Do they work at your side? If yes, could you modify them with the exact your setup so we can see the problem locally?

Kind regards,
Helen
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0
Marek
Top achievements
Rank 1
answered on 11 Feb 2011, 12:07 PM
Hi,

I tracked this bug using .Net Reflector and debugging your code. This problem occurs when in js this line is used

tab.set_imageUrl(menuItemImageUrl);

 and menuItemImageUrl is null so then your code method

      if (dictionary.ContainsKey("imageUrl"))
      {
        this.ImageUrl = dictionary["imageUrl"].ToString();
      }
in class NavigationItem.cs in line 61
throws an exception because dictionary contains key "imageUrl" but value of this key is null so dictionary["imageUrl"].ToString() fails. Of course is's because tab.set_imageUrl(null) and it can be checked in js code before set null to tab image url but it will be better code to do it before getting value of specified key from dictionary. For example if(!String.IsNullOrEmpty(dictionary["imageUrl"])){ this.ImageUrl = dictionary["imageUrl"].ToString();.}. I attached example app showing this problem
0
Helen
Telerik team
answered on 11 Feb 2011, 04:29 PM
Hi Marek,

Could you please open a support ticket and re-attach the files? Our forums do not allow file attachments(excepting images).

Kind regards,
Helen
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0
KK60
Top achievements
Rank 1
answered on 13 Jan 2014, 06:08 PM

I am now having a similar problem after upgrading to the most current version (v2013.3.1114.40.) 



- It happens after a postback from a linkbutton on the page containing the tabstrip, multipage and pageviews.



- However, it only happens if I scroll the tabstrip to the last tab first.  (My tabstrip is several tabs longer than is visible when the page is first displayed.)  And, the scrolling must be complete such that the right side scroll button becomes disabled.



- It does not happen if I reduce the number of tabs to avoid scrolling.



- I have not seen this behavior with the many previous versions I have used.



- This happens in IE11, but not Firefox and not Safari



Here is the stack trace:



Input string was not in a correct format.



Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 



Exception Details: System.FormatException: Input string was not in a correct format.



Source Error:



An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.


Stack Trace:



[FormatException: Input string was not in a correct format.]
   System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) +10896279
   System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info) +145
   System.ComponentModel.Int32Converter.FromString(String value, NumberFormatInfo formatInfo) +50
   System.ComponentModel.BaseNumberConverter.ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, Object value) +328

[Exception: -1026.4 is not a valid value for Int32.]
   System.ComponentModel.BaseNumberConverter.ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, Object value) +457
   System.ComponentModel.TypeConverter.ConvertFromInvariantString(String text) +43
   System.Web.Script.Serialization.ObjectConverter.ConvertObjectToTypeInternal(Object o, Type type, JavaScriptSerializer serializer, Boolean throwOnError, Object& convertedObject) +495
   System.Web.Script.Serialization.ObjectConverter.ConvertObjectToTypeMain(Object o, Type type, JavaScriptSerializer serializer, Boolean throwOnError, Object& convertedObject) +145
   System.Web.Script.Serialization.ObjectConverter.ConvertDictionaryToObject(IDictionary`2 dictionary, Type type, JavaScriptSerializer serializer, Boolean throwOnError, Object& convertedObject) +858
   System.Web.Script.Serialization.ObjectConverter.ConvertObjectToTypeInternal(Object o, Type type, JavaScriptSerializer serializer, Boolean throwOnError, Object& convertedObject) +66
   System.Web.Script.Serialization.ObjectConverter.ConvertObjectToTypeMain(Object o, Type type, JavaScriptSerializer serializer, Boolean throwOnError, Object& convertedObject) +145
   System.Web.Script.Serialization.ObjectConverter.AssignToPropertyOrField(Object propertyValue, Object o, String memberName, JavaScriptSerializer serializer, Boolean throwOnError) +215
   System.Web.Script.Serialization.ObjectConverter.ConvertDictionaryToObject(IDictionary`2 dictionary, Type type, JavaScriptSerializer serializer, Boolean throwOnError, Object& convertedObject) +1153
   System.Web.Script.Serialization.ObjectConverter.ConvertObjectToTypeInternal(Object o, Type type, JavaScriptSerializer serializer, Boolean throwOnError, Object& convertedObject) +66
   System.Web.Script.Serialization.ObjectConverter.ConvertObjectToTypeMain(Object o, Type type, JavaScriptSerializer serializer, Boolean throwOnError, Object& convertedObject) +145
   System.Web.Script.Serialization.JavaScriptSerializer.Deserialize(JavaScriptSerializer serializer, String input, Type type, Int32 depthLimit) +66
   System.Web.Script.Serialization.JavaScriptSerializer.Deserialize(String input) +70
   Telerik.Web.UI.RadTabStrip.LoadPostData(String postDataKey, NameValueCollection postCollection) +234
   Telerik.Web.UI.RadDataBoundControl.System.Web.UI.IPostBackDataHandler.LoadPostData(String postDataKey, NameValueCollection postCollection) +45
   System.Web.UI.Page.ProcessPostData(NameValueCollection postData, Boolean fBeforeLoad) +734
0
Aneliya Petkova
Telerik team
answered on 16 Jan 2014, 09:15 AM

Hello Frank,

Thank you for contacting us.

We want to let you know that the issue with RadTabStrip in IE11 is fixed and will be available in Q3 SP2, expected in the end of January.

Regards,
Aneliya Petkova
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.
Tags
TabStrip
Asked by
giovaneBrazil
Top achievements
Rank 1
Answers by
Helen
Telerik team
Marek
Top achievements
Rank 1
KK60
Top achievements
Rank 1
Aneliya Petkova
Telerik team
Share this question
or