Highlighted
Micro Focus Expert
Micro Focus Expert
146 views

(SM) Support Tip: How to fix Error "TypeError: result.funcObj has no properties at char 1"

When converting WSDL to JS, the following errors may occur:

Process panel execute.js in RAD run.wsdl2js encountered error in line 1 (run.wsdl2js,execute.js)
Cannot evaluate expression (run.wsdl2js,execute.js)
Cannot evaluate expression (run.wsdl2js,execute.js)
Bad arg(2) oper = (run.wsdl2js,execute.js)
Cannot evaluate expression (run.wsdl2js,execute.js)
Script 'SOAP'  line 3421: ERROR TypeError: result.funcObj has no properties at char 1
Unrecoverable error in application:  soa.wsdl2js on panel execute.js
 
From above errors, the line number may change because .
Around lines 3400 and 3500 in the SOAP Script Library, there are some ELSE IF statements that contains "if ( elemName == " some of them have an additional validation (&& result.funcObj != undefined) and some of them doesn’t.

Add the extra validation in the IF statement above the line referenced in the error. For example:

Change the line 3419 in the SOAP Script Library from:
  if ( elemName == "restriction" )
 
To:
  if ( elemName == "restriction" && result.funcObj != undefined )

This change will permit the WSDL to be converted to JS.

Labels (1)
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.