[IronPython] Loading Images from XAML with XamlReader (WPF)

2007-12-13 Thread Michael Foord
Hello guys, I'm struggling to load images from XAML using the XamlReader with IronPython. The equivalent with compiled XAML and C# works fine - however this doesn't directly use the XamlReader so I wonder if it is an issue with that? The Python code is: import clr clr.AddReference("Presentati

Re: [IronPython] [python] Loading Images from XAML with XamlReader (WPF)

2007-12-13 Thread Michael Foord
Just to clarify - creating an image directly from code *does* work. But I still want (need?) to know why it doesn't work when loaded from XAML? This is the working code: import clr clr.AddReference("PresentationFramework") clr.AddReference("PresentationCore") from System import Uri, UriKind fro

Re: [IronPython] [python] Loading Images from XAML with XamlReader (WPF)

2007-12-13 Thread Michael Foord
Hmmm... providing the full path to the image works fine. But that is a problem as I don't want to do that... *sigh* Michael Michael Foord wrote: > Hello guys, > > I'm struggling to load images from XAML using the XamlReader with > IronPython. The equivalent with compiled XAML and C# works fine

Re: [IronPython] [python] Loading Images from XAML with XamlReader (WPF)

2007-12-13 Thread Michael Foord
Sorry about the noise guys, but having found the solution I guess I ought to share it. The answer is (wait for it...)... use site of origin relative syntax for the Source tag. Source="pack://siteoforigin:,,,/image.jpg" And its such an obvious syntax, how could I have missed it. :-) Gory detail

[IronPython] Python libraries

2007-12-13 Thread John Fletcher
All, I am absolutely a new bie to python and Iron python. My target application has chunk of C# code and existing python code. I would like to integrate both of them. I am using Visual Studio 2005 with .NET. I understood from the blogs and on the internet that, it is possible to integrate both of

Re: [IronPython] [python] Python libraries

2007-12-13 Thread Michael Foord
John Fletcher wrote: > All, > > I am absolutely a new bie to python and Iron python. > > My target application has chunk of C# code and existing python code. I > would like to integrate both of them. I am using Visual Studio 2005 > with .NET. I understood from the blogs and on the internet that,

Re: [IronPython] [python] Loading Images from XAML with XamlReader (WPF)

2007-12-13 Thread John Messerly
Michael Foord wrote: > Sorry about the noise guys, but having found the solution I guess I > ought to share it. The answer is (wait for it...)... use site of origin > relative syntax for the Source tag. > > Source="pack://siteoforigin:,,,/image.jpg" > > And its such an obvious syntax, how could I

[IronPython] -X:SaveAssemblies

2007-12-13 Thread Lee Culver
I use the -X:SaveAssemblies command to compile and pass around tools that I create with IronPython... I've noticed that it fails on 2.0A6. Specifically, the exe that it generates gives an "invalid executable" dialog box in windows (with the 3 dlls in the same directory as the .exe file). Is t

Re: [IronPython] -X:SaveAssemblies

2007-12-13 Thread Dino Viehland
In v2.0 we currently don't support re-running the assemblies that are saved to disk. There are a number of places where to simplify things we've taken a dependency of passing live objects from compilation through to runtime. Unfortunately I don't know when we'll be fixing that yet. You're not