Quick Tip: using an object as custom property

Monday, December 9, 2024 at 12:54 PM UTC

Just for my own record because I always forget:

If you ever need to pass any object data to a custom control, use this as the property data type:

com.ibm.jscript.std.ObjectObject

or

com.ibm.jscript.std.ArrayObject

depending on if you just need one or more objects.

This is handy if you use your custom control in a repeat where the looping element is a complex object. Surprisingly this is not a selectable option in the property editor, so you have to type this manually as the data type.






Latest comments to this post

Patrick Kwinten wrote on 11.12.2024, 19:43

I guess if you just write 'object' for the Type for the Property you are already good to go. https://xcellerant.wordpress.com/2016/04/12/xpages-tip-passing-an-array-to-a-custom-control-property/

 Link to this comment
Patrick Kwinten wrote on 11.12.2024, 19:35

I approve this way of application documentation :-)

 Link to this comment
Fredrik Norling wrote on 10.12.2024, 15:53

Do you also have your blog as a secondary memory bank Laughing

 Link to this comment

Leave a comment right here