|
Hi Sudha, <snip> in rpg, D getTestOBJ PR O ExtProc(*JAVA: D 'com.sud.test.TestURL' D *CONSTRUCTOR) Added the string to the call * java method D OpenConn PR O Class(*JAVA:'java.lang.String') D ExtProc(*JAVA: d 'com.sud.test.TestURL': d 'urlOpenConnection') d iUrl like(sUrl) Define TestURL Object: D testURL S O Class(*JAVA:'com.sud.test.TestURL) Call constructor as: eval testURL = getTestURL() Call method as: eval srtn = urlOpenConn(testURL:sUrl) and now I get error in constructor. Cause . . . . . : RPG procedure CALLCHECK3 in program DSRAMANUJA/CALCHECK3 received Java exception "java.lang.NoClassDefFoundError: com/sud/test/TestURL" when calling method "<init>" with signature "()V" in class "com.sud.test.TestURL". </snip> Firstly, You have a constructor prototype defined with the name getTestOBJ, but you are using a call to the method get TestURL(). The constructor should be called using: eval testURL = getTestOBJ() Secondly, your open connection method call is incorrect. The prototype name is OpenConn but you use urlOpenConn(testURL:sUrl). The method call should be: eval srtn = OpenConn(testURL:sUrl) Try that and see how it goes. Cheers Larry
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.