| Summary: | Runtime error when accessing Record field by string literal | ||
|---|---|---|---|
| Product: | z_Archived | Reporter: | Huang Ji Yong <hjiyong> |
| Component: | EDT | Assignee: | Scott Greer <greer> |
| Status: | CLOSED FIXED | QA Contact: | |
| Severity: | major | ||
| Priority: | P3 | ||
| Version: | unspecified | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Windows XP | ||
| Whiteboard: | |||
Fixed. Verified in 201110202102 |
Steps to recreate: 1. Create a new RUI Handler. 2. Copy the source below handler testRecordField type RUIhandler{initialUI =[], onConstructionFunction = start, cssFile = "css/testBugs.css", title = "testRecordField"} function start() rec myRec1 { field1 = "Row 1, Column 1", field2 = "Row 1, Column 2"}; syslib.writestdout(rec["field1"]); end end Record myRec1 field1 String; field2 String; end 3. Run in VE, open in external browser. The following error occurs Could not render UI TypeError: Object [type=client.myRec1] has no method 'ezeGet' at [object Object].start (testRecordField.js:56:51) at new (testRecordField.js:6:9) at [object Object].eze$$thisClass (egl.js:800:27) at testRecordField.html?contextKey=55:75:22 at Function.eze$$loadScripts (testRecordField.html?contextKey=55:51:3) at testRecordField.html?contextKey=55:49:43 at HTMLScriptElement. (testRecordField.html?contextKey=55:37:4) Object [type=client.myRec1] has no method 'ezeGet' [CRRUI2094E] Here are the EGL function calls leading to this error: myRec1.<init>() [native JavaScript] client/testRecordField.egl() at line 14 testRecordField.<init>() [native JavaScript] Uncaught TypeError: Object [type=client.myRec1] has no method 'ezeGet' testBugs/client/testRecordField.html?contextKey=55:90 [CRRUI2095E] Could not find the EGL function calls leading to this error The error happens in line 56 of the handler generated js file: eze$Temp1 = egl.eglx.lang.EString.ezeCast(rec.ezeGet("field1")); // ezeGet is not defined