Hello,
I'm trying to get a handle to a file using parseDisplayName:
sh = pythoncom.CoCreateInstance(shell.CLSID_ShellFSFolder,
None,
pythoncom.CLSCTX_INPROC_SERVER,
shell.IID_IShellFolder)
objtup = sh.Pa
As indicated in the docs, ParseDisplayName takes 3 params - hwnd,
bindContext, displayName. You are passing None for the hwnd, which is
invalid. You probably want to pass (0, None, r"e:\...")
Also documented, the return value is a tuple of (cchEaten, pidl, attr) - see
the MS docs for this interf
I am trying to use ScriptControl under Excel (Windows XP) with the code:
Global sc As New MSScriptControl.ScriptControl
Public Function os_getcwd()
sc.Language = "python"
sc.ExecuteStatement ("import os")
os_getcwd = sc.Eval("os.getcwd()")
End Function
When setting the language to python I
This is indeed an interesting thing do to. The 'right' way to create a
singleton COM object is probably to run an NT Service that hosts the COM
object. The COM Service Control Manager decides when to spin up new
processes for LocalServer32 server object creation requests. You need a
process to
Argh! Well, it turns out that the real problem was that when creating
a mutex for a module-level singleton you should not store a ref to the
handle in an instance that might find itself getting popped. Assign
to a class variable that will stick. D'oh!
I will take a look at setting up the COM ob