[Ironruby-core] Reading files in Dynamic Silverlight

Ivan Porto Carrero ivan at flanders.co.nz
Sat Apr 5 19:00:25 EDT 2008


Hi

I can't work out how I can read external xaml files from Silverlight with
IronRuby.
I've tried to use System::IO::File and StreamReader but both give me a
MethodAccessException.

How would I accomplish reading a xaml file in the xap with IronRuby and
Silverlight.

I would like to create a user control and load that into my main app.

System.IO.Stream s = this.GetType().Assembly.GetManifestResourceStream(
"story_details_view.xaml")

_root = this.InitializeFromXaml(new System.IO.StreamReader(s).ReadToEnd())
as UserControl;

I would also like to try to read an external xaml file for skinning
purposes.
Is that possible at this moment?

Cheers
Ivan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/ironruby-core/attachments/20080406/5b6d5e46/attachment.html 


More information about the Ironruby-core mailing list