Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » EGL Development Tools » Error when adding record parts to rui handler
Error when adding record parts to rui handler [message #761788] Wed, 07 December 2011 03:42 Go to next message
Bob NIcholson is currently offline Bob NIcholsonFriend
Messages: 62
Registered: December 2011
Location: Seattle
Member
EDT:Tutorial: RUI With DataBase Lesson 4
Create a data grid to hold a set of database rows Step 5

After adding the code to initialize the grid with

function start()
allPayments_ui.data =
[
new paymentRec{category = 1, description = "test01", amount = 100.00},
new paymentRec{category = 2, description = "test02", amount = 200.00},
new paymentRec{category = 3, description = "test03", amount = 300.00}
];
end




I get the following error when trying to design or preview.

Could not render UI
Object expected
[CRRUI2094E] Here are the EGL function calls leading to this error:

Div.<init>() [native JavaScript]
Div.<init>() [native JavaScript]
org/eclipse/edt/rui/widgets/Box.egl() at line 22
Box.<init>() [native JavaScript]
myHandler.<init>() [native JavaScript]

Object expected
PaymentClient/handlers/myHandler.js?contextKey=10:27
[CRRUI2095E] Could not find the EGL function calls leading to this error


If I remove the code, then I can design or preview.

I have the same problem if I remove or comment out the code above and then add the selectedPayment record. So, it seems to be related to adding the record part.

I'm not sure if this is caused by something I'm doing wrong or if this is a bug.

Thanks for any help.

Bob
Re: Error when adding record parts to rui handler [message #761819 is a reply to message #761788] Wed, 07 December 2011 05:41 Go to previous messageGo to next message
fahua jin is currently offline fahua jinFriend
Messages: 58
Registered: July 2011
Member
Bob,

I tried the tutorial to the step for initializing the data of allPayments_ui, but could not reproduce your problem. Could you please attach your project to this thread?
Re: Error when adding record parts to rui handler [message #761828 is a reply to message #761819] Wed, 07 December 2011 06:08 Go to previous messageGo to next message
Will Smythe is currently offline Will SmytheFriend
Messages: 41
Registered: July 2009
Member
Bob - what version of the EGL tools are you using? (you can tell by going to Help > About Eclipse and clicking the green EGL icon/button). It should be something like: 0.7.0.v201111291320
Re: Error when adding record parts to rui handler [message #762181 is a reply to message #761828] Wed, 07 December 2011 16:55 Go to previous messageGo to next message
Bob NIcholson is currently offline Bob NIcholsonFriend
Messages: 62
Registered: December 2011
Location: Seattle
Member
Hi, Will

Here's the version.

Version: 0.7.0.v201111291320-1CT-Fiv5_LLLMCVMu5Y
Re: Error when adding record parts to rui handler [message #762187 is a reply to message #762181] Wed, 07 December 2011 17:06 Go to previous messageGo to next message
Will Smythe is currently offline Will SmytheFriend
Messages: 41
Registered: July 2009
Member
Hi Bob - you are running the correct version. Can you export your project (File > Export > Archive File and then just check the box next to your project) and attach?
Re: Error when adding record parts to rui handler [message #762202 is a reply to message #761819] Wed, 07 December 2011 17:37 Go to previous messageGo to next message
Bob NIcholson is currently offline Bob NIcholsonFriend
Messages: 62
Registered: December 2011
Location: Seattle
Member
I'm not sure how much you want me to send or how to send it. Should I upload the entire workspace? Not sure it will fit withing max size allowed. Each of the three projects or just the client. Please let me know.

Thanks
Re: Error when adding record parts to rui handler [message #762209 is a reply to message #762187] Wed, 07 December 2011 17:53 Go to previous messageGo to next message
Bob NIcholson is currently offline Bob NIcholsonFriend
Messages: 62
Registered: December 2011
Location: Seattle
Member
Hi, Will

I'm attaching a zip file containing all three related projects. I'm accessing my iSeries data base for the payment records rather than the Derby.

thanks
Re: Error when adding record parts to rui handler [message #762378 is a reply to message #762209] Thu, 08 December 2011 00:42 Go to previous messageGo to next message
fahua jin is currently offline fahua jinFriend
Messages: 58
Registered: July 2011
Member
Bob,

Thanks for uploading the project.

The problem is that the handler has a reference to a record defined in project PaymentService, but the PaymentService project only configured with Java generation. To resolve the record definition in the handler, the record should be generated into JavaScript as well.

You can resolve the problem by changing the Compiler setting of the package containing record definition. Expand the PaymentService project > Right click the 'records' package > properties > EGL Compiler > check 'Override generation settings from /PaymentService' > check 'JavaScript generator' > click 'OK' > reopen the handler with VE.

Compiler setting is a new approach for configuring the target language generation. If a package configured with both JavaScript & Java generator, which means that the parts in that package will be generated to both JavaScript & Java code. For example, you can put the record definition in that package which will be used in either RUI handler and service. If only 1 compiler setting is specified, then 1 corresponding target language will be generated.
Re: Error when adding record parts to rui handler [message #762400 is a reply to message #762378] Thu, 08 December 2011 01:53 Go to previous message
Bob NIcholson is currently offline Bob NIcholsonFriend
Messages: 62
Registered: December 2011
Location: Seattle
Member
Thanks, that solved my problem.

[Updated on: Thu, 08 December 2011 02:08]

Report message to a moderator

Previous Topic:Timestamps and nulls
Next Topic:Debug
Goto Forum:
  


Current Time: Thu Apr 18 17:09:24 GMT 2024

Powered by FUDForum. Page generated in 0.02706 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top