<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-2" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Thanks. It works for me know. I don't remember exactly what I did wrong
but probably I forgot to pack System.Windows.Controls.dll form SL SDK
into SLToolkit.zip and it is probably referenced from
System.Windows.Controls.Data.dll .<br>
<br>
--<br>
-- Lukáš<br>
<br>
<br>
Jimmy Schementi wrote:
<blockquote
 cite="mid:1B42307CD4AADD438CDDA2FE1121CC921731311E@TK5EX14MBXC136.redmond.corp.microsoft.com"
 type="cite">
  <meta http-equiv="Content-Type" content="text/html; ">
  <meta name="Generator" content="Microsoft Word 14 (filtered medium)">
  <style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";
        color:black;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
tt
        {mso-style-priority:99;
        font-family:"Courier New";}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
  <div class="WordSection1">
  <p class="MsoNormal"><span
 style="font-size: 11pt; font-family: &quot;Calibri&quot;,&quot;sans-serif&quot;; color: rgb(31, 73, 125);">Lukas,<o:p></o:p></span></p>
  <p class="MsoNormal"><span
 style="font-size: 11pt; font-family: &quot;Calibri&quot;,&quot;sans-serif&quot;; color: rgb(31, 73, 125);"><o:p> </o:p></span></p>
  <p class="MsoNormal"><span
 style="font-size: 11pt; font-family: &quot;Calibri&quot;,&quot;sans-serif&quot;; color: rgb(31, 73, 125);">When
you use ExtensionPart, it calls Assembly.Load on each file in the zip
file referenced, so you don&#8217;t need to do clr.Addreference.<o:p></o:p></span></p>
  <p class="MsoNormal"><span
 style="font-size: 11pt; font-family: &quot;Calibri&quot;,&quot;sans-serif&quot;; color: rgb(31, 73, 125);"><o:p> </o:p></span></p>
  <p class="MsoNormal"><span
 style="font-size: 11pt; font-family: &quot;Calibri&quot;,&quot;sans-serif&quot;; color: rgb(31, 73, 125);">System.Windows.Data.dll
and System.Windows.Controls.Data.dll are not DLLs in Silverlight; they
are in the Silverlight SDK. So you&#8217;ll have to package them up into a
separate zip file which you include in your AppManfest, just like you
did with the SLToolkit.zip.<o:p></o:p></span></p>
  <p class="MsoNormal"><span
 style="font-size: 11pt; font-family: &quot;Calibri&quot;,&quot;sans-serif&quot;; color: rgb(31, 73, 125);"><o:p> </o:p></span></p>
  <p class="MsoNormal"><span
 style="font-size: 11pt; font-family: &quot;Calibri&quot;,&quot;sans-serif&quot;; color: rgb(31, 73, 125);">~js<o:p></o:p></span></p>
  <p class="MsoNormal"><span
 style="font-size: 11pt; font-family: &quot;Calibri&quot;,&quot;sans-serif&quot;; color: rgb(31, 73, 125);"><o:p> </o:p></span></p>
  <div>
  <div
 style="border-style: solid none none; border-color: rgb(181, 196, 223) -moz-use-text-color -moz-use-text-color; border-width: 1pt medium medium; padding: 3pt 0in 0in;">
  <p class="MsoNormal"><b><span
 style="font-size: 10pt; font-family: &quot;Tahoma&quot;,&quot;sans-serif&quot;; color: windowtext;">From:</span></b><span
 style="font-size: 10pt; font-family: &quot;Tahoma&quot;,&quot;sans-serif&quot;; color: windowtext;">
<a class="moz-txt-link-abbreviated" href="mailto:users-bounces@lists.ironpython.com">users-bounces@lists.ironpython.com</a>
[<a class="moz-txt-link-freetext" href="mailto:users-bounces@lists.ironpython.com">mailto:users-bounces@lists.ironpython.com</a>] <b>On Behalf Of </b>Lukas
Cenovsky<br>
  <b>Sent:</b> Tuesday, March 23, 2010 5:42 PM<br>
  <b>To:</b> <a class="moz-txt-link-abbreviated" href="mailto:users@lists.ironpython.com">users@lists.ironpython.com</a><br>
  <b>Subject:</b> [IronPython] AddReference to Silverlight toolkit
assemblies<o:p></o:p></span></p>
  </div>
  </div>
  <p class="MsoNormal"><o:p> </o:p></p>
  <p class="MsoNormal">Hi all,<br>
I use Silverlight toolkit in my IronPython Silverlight app. To lower
bandwidth, I put all necessary Silverlight toolkit .dlls into separate
file called <i>SLToolkit.zip</i> which I reference in AppManifest.xaml:<br>
  <br>
  <tt><span style="font-size: 10pt;">  &lt;Deployment.ExternalParts&gt;</span></tt><span
 style="font-size: 10pt; font-family: &quot;Courier New&quot;;"><br>
  <tt>    &lt;ExtensionPart Source="Microsoft.Scripting.zip" /&gt;</tt><br>
  <tt>    &lt;ExtensionPart Source="SLToolkit.zip" /&gt;</tt><br>
  <tt>  &lt;/Deployment.ExternalParts&gt;</tt></span><br>
  <br>
This works nicely if I don't need to reference assembly already
existing in Silverlight - e.g. I do<br>
  <br>
  <tt><span style="font-size: 10pt;">clr.AddReference('System.Windows.Controls.Data')</span></tt><br>
  <br>
and use <i>DataGrid</i>. Unfortunately, when I need to reference <i>PagedCollectionView
  </i>from System.Windows.Data, this approach does not work. Trying <br>
  <br>
  <tt><span style="font-size: 10pt;">from System.Windows.Data import
PagedCollectionView</span></tt><br>
  <br>
fails on <i>ImportError: Cannot import name PagedCollectionView</i>.
Doing <br>
  <br>
  <tt><span style="font-size: 10pt;">import System.Windows.Data</span></tt><span
 style="font-size: 10pt; font-family: &quot;Courier New&quot;;"><br>
  <tt>System.Windows.Data.PagedCollectionView(some_data)</tt></span><br>
  <br>
fails with <i>AttributeError: attribute 'PagedCollectionView' of
'namespace#' object is read-only</i>. When I try to add<br>
  <br>
  <tt><span style="font-size: 10pt;">clr.AddReference('System.Windows.Data')</span></tt><br>
  <br>
if fails with: <i>IOError: [Errno 2] could not find assembly:
System.Windows.Data (check the Web server)</i>.<br>
  <br>
The only way how to make this work is to put <tt><span
 style="font-size: 10pt;">System.Windows.Data.dll</span></tt> into .xap
file and reference it with<br>
  <br>
  <tt><span style="font-size: 10pt;">clr.AddReferenceToFile('System.Windows.Data.dll')</span></tt><span
 style="font-size: 10pt; font-family: &quot;Courier New&quot;;"><br>
  <tt>from System.Windows.Data import PagedCollectionView</tt></span><br>
  <br>
  <br>
Is there a way to make it work when <tt><span style="font-size: 10pt;">System.Windows.Data.dll</span></tt>
is in the separate file? Or should I use another approach?<br>
  <br>
Thanks, <br>
  <br>
--<br>
-- Lukáš<o:p></o:p></p>
  </div>
  <pre wrap="">
<hr size="4" width="90%">
_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@lists.ironpython.com">Users@lists.ironpython.com</a>
<a class="moz-txt-link-freetext" href="http://lists.ironpython.com/listinfo.cgi/users-ironpython.com">http://lists.ironpython.com/listinfo.cgi/users-ironpython.com</a>
  </pre>
</blockquote>
<br>
</body>
</html>