[IronPython] Using WebClient with Gestalt
Lukas Cenovsky
cenovsky at bakalari.cz
Thu Oct 28 17:32:31 CEST 2010
On 28.10.2010 16:34, Mark Heath wrote:
> I'm writing an IronPython Silverlight application and trying to use
> WebClient to download some xaml so I can use XamlReader.Load to load
> it. I have the following code in a .py file that is referenced by my
> main HTML page:
>
> wc = WebClient()
> wc.DownloadStringCompleted += self.xamlDownloaded
> wc.DownloadStringAsync(Uri('star.xaml',UriKind.Relative))
>
> however, in the completed handler I get a SystemError - not found. I
> know that the xaml file is present, so I'm wondering if it is looking
> for it relative to dlr.xap. I didn't get much more success with an
> absolute Uri - just a SystemError with no message at all, which I
> guess could be due to Silverlight cross-domain request permissions.
>
> Any suggestions for how I can get this working?
>
> And another quick question while I'm at it. Are there any known issues
> with IronPython and data-binding in Silverlight? I converted an
> IronPython WPF app to Silverlight that was using MVVM, but in
> Silverlight none of the bindings worked at all.
For binding, you have to user clrtype.py. See my blog:
http://gui-at.blogspot.com/2009/11/inotifypropertychanged-and-databinding.html
--
-- Lukáš
More information about the Ironpython-users
mailing list