pythoncom + set property

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Fabien SK

    pythoncom + set property

    Hi,

    I am using "MSSOAP" as COM object and I would like to put a property to
    an object, but I can not make it work. My code looks like that:

    obj = win32com.client .Dispatch("MSSO AP.SoapClient30 ")
    obj.MSSoapInit( "http://server/wsdl");
    obj.ClientPrope rty("ServerHTTP Request") = 1

    But it doesn't work. "ClientProperty ("ServerHTTPReq uest")" should return
    a COM property that I should be able to get or set.
    I know that for simpler problem the work around is:

    obj.SetSomeProp erty(123)
    print obj.SomePropert y(

    The problem is that I get the property by a function call, and win32com
    converts it directly to the value:
    print obj.ClientPrope rty("ServerHTTP Request")
    [color=blue][color=green][color=darkred]
    >>> print type(obj.Client Property("Serve rHTTPRequest"))[/color][/color][/color]
    <type 'bool'>

    If you have any idea...

    Fabien

Working...