﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>CapableObjects Forums / ECO / General discussions  / Devired attribute of type List / Latest Posts</title><generator>InstantForum.NET v4.1.4</generator><description>CapableObjects Forums</description><link>http://www.capableobjects.com/apps/InstantForum414/</link><webMaster>forums@capableobjects.com</webMaster><lastBuildDate>Wed, 08 Feb 2012 22:54:59 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: Devired attribute of type List</title><link>http://www.capableobjects.com/apps/InstantForum414/Topic4916-4-1.aspx</link><description>I had a trial with a derived attribute of type collection(string) and was amazing that it works fine. In earlier ECO versions we could use only simple types for attributes. Now I could get attribute values at run time. As you mentioned model validator throws the error message, but I gues you can ignore it.</description><pubDate>Wed, 03 Mar 2010 18:40:09 GMT</pubDate><dc:creator>efim</dc:creator></item><item><title>RE: Devired attribute of type List</title><link>http://www.capableobjects.com/apps/InstantForum414/Topic4916-4-1.aspx</link><description>Hi,&lt;br&gt;you can always use commaList, that coverts collection of string to comma separated list.</description><pubDate>Wed, 03 Mar 2010 09:11:25 GMT</pubDate><dc:creator>Alex Vedmedenko</dc:creator></item><item><title>RE: Devired attribute of type List</title><link>http://www.capableobjects.com/apps/InstantForum414/Topic4916-4-1.aspx</link><description>I would be happy with a string[], but when I try that for a derived attribute of type String[] with this OCL:&lt;/P&gt;&lt;P&gt;self.Orders.M3Id&lt;/P&gt;&lt;P&gt;I get this during Validate Model:&lt;/P&gt;&lt;P&gt;MVE209 Invalid DerivationOCL: Type mismatch: Expected System.String[] got Collection(System.String). Expression: "self.Orders.M3Id" [Delivery.OL]&lt;/P&gt;&lt;P&gt;Also, I only get this validation error in the PMP designer Validate Model tool button - Show Model Errors in Modlr does not report it.&lt;/P&gt;&lt;P&gt;Second also, I do realize that I can (and should, and am now) get what I want via the derived association Orders but I was trying something fancy because I just wanted a list of Order ID's. I am just reporting what appears to be a small hole.</description><pubDate>Tue, 02 Mar 2010 22:00:59 GMT</pubDate><dc:creator>RickWeyrauch</dc:creator></item><item><title>RE: Devired attribute of type List</title><link>http://www.capableobjects.com/apps/InstantForum414/Topic4916-4-1.aspx</link><description>Attributes can't have types that can be modified. Your alternative is to use string[]. &lt;br&gt;</description><pubDate>Tue, 02 Mar 2010 14:26:05 GMT</pubDate><dc:creator>Jonas Hogstrom</dc:creator></item><item><title>Devired attribute of type List</title><link>http://www.capableobjects.com/apps/InstantForum414/Topic4916-4-1.aspx</link><description>I am getting this error when I try to make a derived attribute of List&amp;lt;String&amp;gt; and Ocl that returns a Collection&amp;lt;String&amp;gt;. It all compiles but Eco does not seem to be able to really do it. See attached picture for model.&lt;/P&gt;&lt;FONT size=1&gt;&lt;P&gt;Model Validation| Exception has been thrown by the target of an invocation.&lt;/P&gt;&lt;P&gt;| System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---&amp;gt; System.InvalidOperationException: Model not Ecoified&lt;/P&gt;&lt;P&gt;| Attribute PickList.OrdersSet has an invalid type: System.Collections.Generic.List`1[System.String]. Only arrays, enums, strings and valuetypes are allowed&lt;/P&gt;&lt;/FONT&gt;</description><pubDate>Sun, 28 Feb 2010 18:41:15 GMT</pubDate><dc:creator>RickWeyrauch</dc:creator></item></channel></rss>
