[IronPython] MapPoint COM object?
Jonathan Jacobs
korpse-ironpython at kaydash.za.net
Mon Apr 17 12:35:11 CEST 2006
Gardner Pomper wrote:
> Hi,
>
> I am trying to manipulate mappoint from an IronPython script. I tried to
> do the COM integration I found in the Tutorial, but it failed. I have
> copied what I did into this email. Can someone take a look and tell me
> what I should have done?
I believe the problem is that your working directory is not in clr.Path (a
Python list), which specifies paths in which to search for assemblies.
>>> import clr
>>> clr.AddReferenceToFile('IconTools.dll')
Traceback (most recent call last):
File , line 0, in input##6
File , line 0, in AddReferenceToFile##7
RuntimeError: Could not add reference to assembly IconTools.dll
>>> import os
>>> clr.Path.append(os.getcwd())
>>> clr.AddReferenceToFile('IconTools.dll')
>>> import IconTools
>>> IconTools
<module IconTools (CLS module)>
>>>
HTH
--
Jonathan
When you meet a master swordsman,
show him your sword.
When you meet a man who is not a poet,
do not show him your poem.
-- Rinzai, ninth century Zen master
More information about the Ironpython-users
mailing list