Or, save a lot of the complexity and instead of binding your hyperlink/button to the displaygroup.displayNextBatch, create a new component-level action called 'displayNextBatch' and bind it to that. This method does the requisite checks, and call the displayNextBatch() method in display group if user is not editing. Or as Josh Bloch would say "favor composition over inheritance".


On Dec 15, 2005, at 1:43 PM, Art Isbell wrote:

On Dec 15, 2005, at 11:32 AM, [EMAIL PROTECTED] wrote:


I created a separate java file for this class MyDisplayGroup and added it to my project.



Then I changed my the instance variable for my localizationCodesDG on my component page to be of type MyDisplayGroup. Finally, I changed the corresponding *.woo file back to

class=MyDisplayGroup;

I got an error similar to my original one:

Error: com.webobjects.foundation.NSForwardException [java.lang.IllegalArgumentException] While trying to set the field "localizationCodesDG" on an object of type LocalizationCodePage we expected a MyDisplayGroup but received a com.webobjects.appserver.WODisplayGroup with a value of sortOrdering=() qualifier=null localKeys=() insertedObjectDefaultValues={} numberOfObjectsPerBatch=2>. This often happens if you forget to use a formatter.


Looks like you're using Java's default package. Maybe you need to create a package for your custom classes and then specify the fully-qualified class name as the error message does for WODisplayGroup. Putting everything into custom packages is probably a good idea even if it doesn't solve this problem.

If this fails, there may be a bug in the logic that creates a WODisplayGroup that's in a WOComponent template. If you're intent on using WODisplayGroup, maybe you should try removing it from the WOComponent template and creating a MyDisplayGroup programmatically.

Aloha,
Art

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/samlist% 40prometheus-systems.com

This email sent to [EMAIL PROTECTED]


_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to