You are correct; that line of code is wrapped with the following:

        daoEngine = win32com.client.Dispatch(r'DAO.DBEngine.36')
        print sys.exc_info()[0]

How can I obtain a more detailed traceback?

On Thu, May 14, 2009 at 5:34 PM, Mark Hammond <> wrote:
On 15/05/2009 9:12 AM, Trevor M. Lango wrote:
I have compiled a Python module using Py2exe.  The *.exe successfully
executes from a command prompt; however, attempting to run the *.exe
from a win32 CreateProcess call results in an error:

!!python/name:pywintypes.com_error ''

The error is produced when the following line of code is executed:

daoEngine = win32com.client.Dispatch(r'DAO.DBEngine.36')

That doesn't look like an error generated by win32com - are you sure you don't have another exception handler in place?  You will need to determine the exact exception and traceback from the failing Dispatch call before we can offer any more clues.