| Summary: | EDT code str == null causes JS message egl.egl.lang.EBoolean.fromEBoolean is not a function | ||
|---|---|---|---|
| Product: | z_Archived | Reporter: | Kathy Carroll <carrollk> |
| Component: | EDT | Assignee: | Project Inbox <edt.javascriptgen-inbox> |
| Status: | CLOSED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | ||
| Version: | unspecified | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Windows XP | ||
| Whiteboard: | |||
this line of JS
if (egl.egl.lang.EBoolean.ezeCast((((egl.egl.lang.NullType.equals({eze$$value : str, eze$$signature : "S;"}, null)) || egl.egl.lang.EBoolean.fromEBoolean(((str) == "")))))) {
causes this runtime message
"egl.egl.lang.EBoolean.fromEBoolean is not a function"
Indirectly fixed verified Closing this defect. |
Functions passed and trace only work when I explicitly defined the parameter type as IN. Would you expect this line of code to work? if(str == null || str == "") It doesn't like the test for null. This is valid in RBD. Is it valid in EDT? package handlers; handler MyHandler type RUIhandler {onConstructionFunction = start, cssFile="css/Alpha.css", title="MyHandler"} function start() SysLib.WriteStdOut("Hello from JavaScript Batch"); passed("something"); end function passed(str String in) SysLib.WriteStdOut("inside passed"); if( str == "" ) // if(str == null || str == "") SysLib.WriteStdOut("Passed string is empty/null"); else SysLib.WriteStdOut("Passed has contents"); end if (str != "OK") str = str + " OK"; end SysLib.WriteStdOut(str); trace(str); end function trace(details string in) syslib.writeStdout(details); end end