<div><span class="gmail_quote">On 12/7/06, <b class="gmail_sendername">Dave Fugate</b> <<a href="mailto:dfugate@microsoft.com">dfugate@microsoft.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div link="blue" vlink="purple" lang="EN-US">
<div>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">OK, I've now recreated your sample in C# and found it basically
works. I just commented out the calls to Columns.Add(…) and
changed the ages from integers to strings just to be on the safe side. </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">On a hunch, I redefined "people" in your original
Python code to:</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> people
= System.Collections.Generic.List[Person]()</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">and</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> people
= System.Collections.Generic.List[System.Object]()</span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);"> </span></p>
<p><span style="font-size: 11pt; color: rgb(31, 73, 125);">Neither of these work either so it does not appear to be a
mismatch between Python and CLR list types. At this point, I'm
fairly sure that there's a bug or unimplemented feature in IronPython
where Python properties do not map to CLR properties as you say. An
educated guess is that this might have something to do with the fact that the
Python property decorator does not give the type. </span></p></div></div></blockquote></div><br>The correct number of rows get created in the grid, so I don't think the problem is with the list. Rather, it is with the objects in the list and the ability to get the attributes of those objects. But I don't know why this should be a problem. Especially with a text column, since any Python object/attribute can be represented as text. So hopefully it will be easy to fix. Thanks for your help.
<br clear="all"><br>-- <br>Patrick K. O'Brien<br>Orbtech <a href="http://www.orbtech.com">http://www.orbtech.com</a><br>Schevo <a href="http://www.schevo.org">http://www.schevo.org</a><br>Louie <a href="http://www.pylouie.org">
http://www.pylouie.org</a>