[python-win32] How to set value with PyIPropertyStore

Tim Roberts timr at probo.com
Mon Oct 14 20:25:01 EDT 2019


Peng Chen wrote:
>
> I'm working on a script to shift video media creation time.
> ....
> I can see there is a function
> PyIPropertyStore.SetValue(key, value) and PyIPropertyStore.Commit()
> to write the date back, but I'm not sure how to construct the value 
> because it requires PyPROPVARIANT type.
> I can't figure out any where to import this type and doesn't know how 
> to construct it.

PyPROPVARIANT is generally a return type.  In a case like this, I would 
expect that you would simply pass the datetime value, and the interface 
code would convert it into a variant.  Have you tried that?  Did you get 
an error?

-- 
Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3389 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://mail.python.org/pipermail/python-win32/attachments/20191014/e3eb9aac/attachment.bin>


More information about the python-win32 mailing list