No worries Mark, many thanks for your help. I am using the default
interface instead which works perfectly. Going through the custom
interface would make the code cleaner but I am happy to live with this
if that means I can use python in the backend :-) I will post here if
I find the answer.
Have
> Unfortunately got the same error ('Invalid class string') with
> 'pywintypes.IID("{...
That is strange - it appears the object itself is throwing that error code.
E_NOINTERFACE is generally the only "expected" error code for QI.
> You mention not supporting IDispatch but this interface inherits
Unfortunately got the same error ('Invalid class string') with
'pywintypes.IID("{...
You mention not supporting IDispatch but this interface inherits
IDispatch. Here is a snippet from it's IDL:
[
odl,
uuid(8D2AD79B-1ADD-4181-BAD4-FF0672A9B6E3),
version(1.0),
dual,
nonextensibl
> Hi Mark,
>
> Thanks for the answer, I tried using the IViewDataView's uiid like
> this (probably in a naive way):
>
> y = view.QueryInterface("{8D2AD79B-1ADD-4181-BAD4-FF0672A9B6E3}")
>
> But that produces the error on that line.
>
> com_error: (-2147221005, 'Invalid class string', None, None
Hi Mark,
Thanks for the answer, I tried using the IViewDataView's uiid like
this (probably in a naive way):
y = view.QueryInterface("{8D2AD79B-1ADD-4181-BAD4-FF0672A9B6E3}")
But that produces the error on that line.
com_error: (-2147221005, 'Invalid class string', None, None)
I read that I can
> import comtypes.gen.ResultsInterfaces as ResInt
> internalView = view.QueryInterface(ResInt.IViewDataView)
ResInt.IViewDataView needs to be converted to either a pywintypes IID
object, or a string in {xxx-xxx-etc} format - but I'm not sure how to
convert between comtypes IIDs and
Hi,
I am porting parts of a large VB application to python (using 2.5)
where the UI must stay in VB for the moment. I am using the Model View
Presenter where my models and presenters are in python and my view is
in VB.
I am having trouble passing the VB views into my python presenters.
The views