Date Posted:
Product: TIBCO Spotfire®
Product: TIBCO Spotfire®
Problem:
Error "Unable to cast object of type 'System.Char' to type 'System.String'." when using Information Links that contain keywords
Solution:
When working with an analysis file, containing information link/s with keywords and loading data on-demand, the client may terminate with the error mentioned below when for example going to Data - Data table properties or inserting a calculated column.
Example error message:
************** Exception Text ************** System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.InvalidCastException: Unable to cast object of type 'System.Char' to type 'System.String'. at Spotfire.Dxp.Data.Formatters.StringFormatter.Format(Object obj) at Spotfire.Dxp.Forms.Data.DataProperties.DataPropertyUtility.FormatPropertyValue(DataType dataType, Boolean isListValued, Object propertyValue, DataPropertyClass propertyClass, IDataPropertyContainer container, Boolean hasInheritedType) at Spotfire.Dxp.Forms.Data.DataProperties.DataPropertyUtility.FormatExistingPropertyValue(String registeredPropertyName, Object propertyValue, DataPropertyClass propertyClass, IDataPropertyContainer container, IDataPropertyRegistry registry) at Spotfire.Dxp.Forms.Data.DataProperties.DataPropertiesControl.InitPropertyDataGridView() at Spotfire.Dxp.Forms.Data.DataProperties.DataPropertiesControl.Init(Document doc, IDataPropertyContainer container) at Spotfire.Dxp.Forms.Data.DataTableProperties.DataTablePropertiesDialog..ctor(DataManager dataManager, DataTable preselectedTable, Boolean modifySaveSettings) at Spotfire.Dxp.Forms.WebView.FormsMenuItems.EditDataTableProperties() at Spotfire.Dxp.Web.Menus.MenuItemHandler.Execute() at Spotfire.Dxp.Forms.WebView.FormsImplWebView.<>c__DisplayClass23_0.<PerformAsynchronousUiOperation>b__0() --- End of inner exception stack trace --- at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor) at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments) at System.Delegate.DynamicInvokeImpl(Object[] args) at System.Windows.Forms.Control.InvokeMarshaledCallbackDo(ThreadMethodEntry tme) at System.Windows.Forms.Control.InvokeMarshaledCallbackHelper(Object obj) at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Windows.Forms.Control.InvokeMarshaledCallback(ThreadMethodEntry tme) at System.Windows.Forms.Control.InvokeMarshaledCallbacks() at System.Windows.Forms.Control.WndProc(Message& m) at System.Windows.Forms.Form.WndProc(Message& m) at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
This is a known issue in TIBCO Spotfire 10.1 and 10.2 and has been addressed in hotfix HF-002 for version 10.2.
In order to fix this the following is needed:
1. Download and install version 10.2 with the latest hotfix.
2. For old, existing analysis files (not created in 10.2 with latest hotfix) that are affected, also make sure to reload the data via Data - Reload all data. keywords: keyword, keywords, information link, Unable to cast object of type 'System.Char' to type 'System.String', exception error
Comments
0 comments
Article is closed for comments.