Ivan Uemlianin wrote: >Roman Yakovenko wrote: > > > >>On 3/28/06, ivan Uemlianin <[EMAIL PROTECTED]> wrote: >> >> >> >> >>>Is there a litle bit extra I need to do, or am I barking up the wrong >>>tree? I suppose I'm looking for something that will allow me to import >>>.net dlls as if they were python modules. >>> >>> >>> >>> >>I could be wrong, but it seems to me that before importing something from >>.net dlls, you should load them first. >> >>import CLR >> >> >>from CLR.System.Reflection import Assembly > > >>my_dll_name = Assembly.LoadWithPartialName( path to dll that does not >>include .dll extension ) >> >>#import namespaces >> >> >>from CLR import TopNamespace > >
>1. Installing Python for .NET as a standalone, and using it in the >interactive session, all of the above, apart from 'from CLR import >TopNamespace' works. 'from CLR import TopNamespace' gets 'ImportError: >cannot import name TopNamespace'. > > Duh. Of course I replace 'TopNamespace' with my own namespace. Please regard this question as a typo. Best Ivan _________________________________________________ Python.NET mailing list - PythonDotNet@python.org http://mail.python.org/mailman/listinfo/pythondotnet