PyZDDE (Python Zemax DDE)
Question: It's first time when I use this tool (pyzdde). When I run simple program error
has occurred!

    
    
    #**************** Add PyZDDE to Python search path **********
    import sys
    PyZDDEPath = 'C:\PyZDDE'  # Assuming PyZDDE was unzipped here!
    
    if PyZDDEPath not in sys.path:
        sys.path.append(PyZDDEPath)
    #************************************************************
    
    import pyzdde.zdde as pyz
    #Create a PyZDDE object
    link = pyz.createLink()
    

ERROR: Unable to establish a conversation with server (err=0x400a). ZEMAX may
not be running! Could not initiate instance.


Answer: The error message says that PyZDDE couldn't create a link to communicate with
Zemax as Zemax may not be running. So, were you running Zemax when executing
the above code?

By the way, you don't need to use the above template any more to use PyZDDE.
Now, there is a pyzdde [PyPI package](https://pypi.python.org/pypi/PyZDDE). So
you can just use pip to install pyzdde. The installation instructions are
[here](https://github.com/indranilsinharoy/PyZDDE#install-pyzdde-from-pypi).
After installing, open Zemax, and then try to run the [spiral spot
example](https://github.com/indranilsinharoy/PyZDDE/wiki#example).

Hope that helps.

