[Python.NET] Importing .NET assembly with "." (dot) in the name

Mark Tigges mtigges at gmail.com
Tue Apr 30 17:21:41 CEST 2013


import is namespace on the AddReference.

The import hooks look in the dll's that you've referenced, and search for
namespaces as per the argument to Accord.  So, you shouldn't import the dll
name.  If the assembly defines the namespace:

namespace AccordImaging
{
.......



Then, you should:

import AccordImaging

After you AddReference


On Mon, Apr 29, 2013 at 7:15 PM, Mikhail Karmyshev <kmike at hotbox.ru> wrote:

> Hello,
> Sorry for possibly dumb question, but is it possible to import an assembly
> with "." (dot) in the name ?
> Without dot, for example "SlimDX.dll" - AddReference works and import
> works too.
> But for "Accord.Imaging.dll" - AddReference is OK, but import fails:
> >>> import Accord.Imaging
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
> ImportError: No module named Accord
>
> Is there a workaround for this or am I doing something wrong?
> Any help appreciated.
> Mikhail
> _________________________________________________
> Python.NET mailing list - PythonDotNet at python.org
> http://mail.python.org/mailman/listinfo/pythondotnet
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/pythondotnet/attachments/20130430/2fef7612/attachment.html>


More information about the PythonDotNet mailing list