[IronPython] Embedding Question

Kristof Wagemans kristof.wagemans at gmail.com
Thu Aug 10 23:19:45 CEST 2006

Isn't engine.LoadAssembly(typeof(SomeAutoCadType).Assembly) easier or is
this different in some way?



From: users-bounces at lists.ironpython.com
[mailto:users-bounces at lists.ironpython.com] On Behalf Of Dino Viehland
Sent: Thursday 10 August 2006 21:17
To: Discussion of IronPython
Subject: Re: [IronPython] Embedding Question


Cool, looks like I was only close though :-) You may have already imported
clr into the default module, but just for the record for those who haven't
you'll need an import clr there.  I just realized I forgot it the 1st time,
and I had a redundant "AddReference" in the delegate call.   I'm assuming
you just fixed all that up, but just in case anyone else needs to do
something like this, here's the correct code:


delegate void AddReference(object assembly);

AddReference adr = engine.CreateMethod<AddReference>("import



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ironpython-users/attachments/20060810/06a8af44/attachment.html>

More information about the Ironpython-users mailing list