Aaaah, OK, I see.  I'll try and burn that into memory.

Cheers Peter.

DAN



On Fri, Jan 25, 2013 at 2:10 PM, Peter Agg <peter....@googlemail.com> wrote:

> Ah yeah, looking at the docs AddProp uses those funky ISIVTCollection
> things to return a collection....
>
>
> for obj in Application.Selection:
>     over = Application.AddProp("Override", obj, "",
> "Vis_Override")["Value"][0]
>
>     param = obj.Properties("Visibility").Parameters("viewvis")
>     over.AddParameterEntry(param)
>
> That should do it though.
>
>
>
> On 25 January 2013 11:59, Dan Yargici <danyarg...@gmail.com> wrote:
>
>> My last mail's formatting may have been scrambled...
>>
>>
>>
>>
>> On Fri, Jan 25, 2013 at 1:58 PM, Dan Yargici <danyarg...@gmail.com>wrote:
>>
>>> Indeed it does!  Try this however, and it fails again.  Seems it's a
>>> quirk with AddProp.  Strange...
>>>
>>> for obj in Application.Selection:
>>>     over = obj.AddProp("Override", oObj, "", "Vis_Override")
>>>      param = obj.Properties("Visibility").Parameters("viewvis")
>>>     over.AddParameterEntry(param)
>>>
>>>
>>> On Fri, Jan 25, 2013 at 1:50 PM, Peter Agg <peter....@googlemail.com>wrote:
>>>
>>>> for obj in Application.Selection:
>>>>     over = obj.AddProperty("Override", False, "Vis_Override")
>>>>     param = obj.Properties("Visibility").Parameters("viewvis")
>>>>     over.AddParameterEntry(param)
>>>>
>>>>
>>>> Does this not work?
>>>>
>>>>
>>>>
>>>> On 25 January 2013 11:34, Dan Yargici <danyarg...@gmail.com> wrote:
>>>>
>>>>> OK, a little help here...
>>>>>
>>>>> This parameter gymnastics gets me every time.  I've tried all manner
>>>>> of variants with no success.  Select an object and then run this:
>>>>>
>>>>> from win32com.client import dynamic
>>>>>
>>>>> xsi = Application
>>>>> pr = xsi.LogMessage
>>>>>
>>>>> for oObj in xsi.Selection:
>>>>> oOverride = xsi.AddProp("Override", oObj, "", "Vis_Override")
>>>>>  oParam =
>>>>> dynamic.Dispatch(oObj).Properties("Visibility").Parameters("viewvis")
>>>>> pr("Look everyone - A Parameter!")
>>>>>  
>>>>> pr("""dynamic.Dispatch(oObj).Properties("Visibility").Parameters("viewvis")"""
>>>>> + " is type: " + oParam.type)
>>>>>  pr("...Yet this next line fails :(")
>>>>>
>>>>> oOverride.AddParameterEntry(dynamic.Dispatch(oObj).Properties("Visibility").Parameters("viewvis"))
>>>>>
>>>>>
>>>>> DAN
>>>>>
>>>>>
>>>>>
>>>>> On Wed, Jan 23, 2013 at 5:10 PM, Christian Gotzinger <
>>>>> cgo...@googlemail.com> wrote:
>>>>>
>>>>>> Thank you for the explanations Stephen and César!
>>>>>>
>>>>>
>>>>>
>>>>
>>>
>>
>

Reply via email to