AnsweredAssumed Answered

How to write a special character in Excel

Question asked by Ram2010mech on May 12, 2017
Latest reply on May 15, 2017 by Ram2010mech

Hi All,

 

I want to write the filter value in Excel , in the filter value is like this [141234354235].

 

AccountID value in the Property = [141234354235]

 

String ID = testExec.getStateValue("AccountID");

 

while executing the Javascript am getting the below error. Please help me on this.

 

Thanks

Ram

 

 

============================================================================
| Error in Script
============================================================================
| Step: Write to an Excel
----------------------------------------------------------------------------
| Message: Sourced file: inline evaluation of: ``import org.apache.poi.xssf.usermodel.XSSFCell; import org.apache.poi.xssf.userm . . . '' : Typed variable declaration : at Line: 22 : in file: inline evaluation of: ``import org.apache.poi.xssf.usermodel.XSSFCell; import org.apache.poi.xssf.userm . . . '' : String ID = testExec .getStateValue ( "AccountID" )

Target exception: java.lang.ClassCastException: Cannot cast java.util.Vector to java.lang.String

----------------------------------------------------------------------------
| Trapped Exception: Sourced file: inline evaluation of: ``import org.apache.poi.xssf.usermodel.XSSFCell; import org.apache.poi.xssf.userm . . . '' : Typed variable declaration : at Line: 22 : in file: inline evaluation of: ``import org.apache.poi.xssf.usermodel.XSSFCell; import org.apache.poi.xssf.userm . . . '' : String ID = testExec .getStateValue ( "AccountID" )

Target exception: java.lang.ClassCastException: Cannot cast java.util.Vector to java.lang.String

| Trapped Message: bsh.TargetError: Sourced file: inline evaluation of: ``import org.apache.poi.xssf.usermodel.XSSFCell; import org.apache.poi.xssf.userm . . . '' : Typed variable declaration : at Line: 22 : in file: inline evaluation of: ``import org.apache.poi.xssf.usermodel.XSSFCell; import org.apache.poi.xssf.userm . . . '' : String ID = testExec .getStateValue ( "AccountID" )

Target exception: java.lang.ClassCastException: Cannot cast java.util.Vector to java.lang.String

----------------------------------------------------------------------------
STACK TRACE
bsh.TargetError: Sourced file: inline evaluation of: ``import org.apache.poi.xssf.usermodel.XSSFCell; import org.apache.poi.xssf.userm . . . '' : Typed variable declaration : at Line: 22 : in file: inline evaluation of: ``import org.apache.poi.xssf.usermodel.XSSFCell; import org.apache.poi.xssf.userm . . . '' : String ID = testExec .getStateValue ( "AccountID" )

Target exception: java.lang.ClassCastException: Cannot cast java.util.Vector to java.lang.String

at bsh.UtilTargetError.toEvalError(UtilTargetError.java:70)
at bsh.UtilEvalError.toEvalError(UtilEvalError.java:94)
at bsh.BSHTypedVariableDeclaration.eval(BSHTypedVariableDeclaration.java:90)
at bsh.Interpreter.eval(Interpreter.java:664)
at bsh.Interpreter.eval(Interpreter.java:758)
at bsh.Interpreter.eval(Interpreter.java:747)
at com.itko.lisa.test.ScriptExecHandler.executeScript(ScriptExecHandler.java:636)
at com.itko.lisa.test.ScriptExecHandler.executeScriptOld(ScriptExecHandler.java:528)
at com.itko.lisa.test.ScriptNode._execute(ScriptNode.java:126)
at com.itko.lisa.test.ScriptNode.execute(ScriptNode.java:103)
at com.itko.lisa.test.TestNode.executeNode(TestNode.java:981)
at com.itko.lisa.test.TestCase.execute(TestCase.java:1283)
at com.itko.lisa.test.TestCase.execute(TestCase.java:1198)
at com.itko.lisa.test.TestCase.executeNextNode(TestCase.java:1183)
at com.itko.lisa.editor.WalkThruPanel.prepAndExecNode(WalkThruPanel.java:1050)
at com.itko.lisa.editor.WalkThruPanel.access$900(WalkThruPanel.java:70)
at com.itko.lisa.editor.WalkThruPanel$10.doCallback(WalkThruPanel.java:963)
at com.itko.util.swing.panels.ProcessingDialog$2.run(ProcessingDialog.java:194)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.ClassCastException: Cannot cast java.util.Vector to java.lang.String
at bsh.Types.castError(Types.java:524)
at bsh.Types.castError(Types.java:512)
at bsh.Types.castObject(Types.java:502)
at bsh.Types.castObject(Types.java:310)
at bsh.Variable.setValue(Variable.java:83)
at bsh.Variable.<init>(Variable.java:49)
at bsh.NameSpace.setTypedVariable(NameSpace.java:703)
at bsh.BSHTypedVariableDeclaration.eval(BSHTypedVariableDeclaration.java:87)
... 16 more
============================================================================

Outcomes