Skip to main content

I don't know if I am missing something obvious here, but I need to ask the question anyway.

 

The premis is that I want to manipulate a list of data from a SmartObject. Perhaps I want to change it to a list of values that I can manipulate in a string or I want to take a list of values and store them in an XML Field.

 

I have tried using a SmartObject event get list method and mapping the output to an XML field with the intent of easily accessing that from a server event in some code. However, when I try to do that, I get this error;

"SmartObject Event xml validation against schema failed: The element 'XmlDocument' has invalid child element 'ClauseName'. List of possible elements expected: 'IncludeSectionBreak, Contract'"

 

Is there a trick to being able to use the SmartObject event to map a list of data into an XML field?

 

As a secondary question, the alternative is for me to use code in my Server Event to access the SmartObject. What is the best way of achieving that? Do I use a class generated from the SmartObject explorer or is there an easier path?

 

Thanks

 

Jeremy

Hi Jermey,

 

I'm not sure about the XML part but you can iterate through a list of data using the Plan per slot - No Destinations options, if your smart object has a read method which expects a single property to retrieve the data, i.e. an ID field

http://help.k2.com/onlinehelp/k2blackpearl/userguide/4.6.5/webframe.html#plan_per_slot_-_no_destinations.html

 

You need to select the ID field on the Destination Rule Options page of the Activity and in the events you place inside this activity you can access the single Id using the "Instance Data" of the Activity Destination Instance. Using this option you could iterate through the list, execute the Read method of the smart object, retrieve the data and process it.

 

Daniel


Jem,

 

I'm also unsure of what role XML is playing in this.  Any chance you could give us a more detailed use case of what we are trying to accomplish here, or perhaps some screenshots of what we have now and an explanation of the process?

 

Regards,

 

Mike


Reply