Re: [python-win32] Object type puzzle

2023-01-07 Thread Tim Roberts
t Jan 07 11:14:59 2023".  So, any line in a message that started with the word "From" needed to be escaped to prevent it from being read as a separator. The traditional escapement was to change it to "> From". -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc.

Re: [python-win32] List all fonts filename

2023-01-05 Thread Tim Roberts
file name.  If there is a file name without a path, it defaults to C:\Windows\Fonts. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list python-win32@py

Re: [python-win32] List all fonts filename

2023-01-03 Thread Tim Roberts
API, and everything in the Win32 API can be accessed through pywin32. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] List all fonts filename

2022-12-30 Thread Tim Roberts
h.html https://stackoverflow.com/questions/5760594/pywin32-enumfontfamilies-breaks-python -- Tim Roberts,t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] Trouble finding MSOLAP provider with adodbapi

2022-12-06 Thread Tim Roberts
your Python bittedness, and most of us run 64-bit Python.  Is there a 64-bit version of the connector? -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing

Re: [python-win32] Pywin32 without the interface

2022-12-02 Thread Tim Roberts
On 12/2/22 12:10 PM, Tim Roberts wrote: On 12/2/22 4:25 AM, QMUL_EECS DVS wrote: Is it related to the fact that I can’t open Visio/ Word windows? If so, is there a way for me to avoid this error? The first and most obvious question is, do you actually have Office and Visio installed

Re: [python-win32] Pywin32 without the interface

2022-12-02 Thread Tim Roberts
bring up a UI window unless you specifically set "xxx.Visible = True", so I'm guessing there's something else going on. -- Tim Roberts,t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.o

Re: [python-win32] Pywin32 without the interface

2022-12-02 Thread Tim Roberts
bring up a UI window unless you specifically set "xxx.Visible = True", so I'm guessing there's something else going on. -- Tim Roberts,t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.o

Re: [python-win32] Pywin32 without the interface

2022-12-02 Thread Tim Roberts
bring up a UI window unless you specifically set "xxx.Visible = True", so I'm guessing there's something else going on. -- Tim Roberts,t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.o

Re: [python-win32] Pywin32 without the interface

2022-11-30 Thread Tim Roberts
Visio and Word through pythoncom, but you don't want the application window to be visible?  That can be done. Please clarify. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org h

Re: [python-win32] Looking for PyWin32 for Python 2.3.1

2022-11-15 Thread Tim Roberts
is present in the 201.1 zip.  I don't know whether that builds for Python 2.1 or not. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list python-win32@python

Re: [python-win32] Looking for PyWin32 for Python 2.3.1

2022-11-15 Thread Tim Roberts
a wrong turn several steps ago.  By learning more about the "why", we can offer a much better overall experience. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ pyth

Re: [python-win32] Windows printing with the use of Device Context

2022-11-07 Thread Tim Roberts
the huge advantage of being cross-platform.  The Windows printing API is, in my expert opinion, peculiar and finicky. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org h

Re: [python-win32] Windows printing with the use of Device Context

2022-11-07 Thread Tim Roberts
nformation about the printer. I don't have another printer to test but my underlying question is : does the coordinates depend on the printer? Absolutely, yes.  Modern printers can be 300, 600, or 1200 dots per inch.  Label printers can use even wilder values. -- Tim Roberts, t...

Re: [python-win32] Unpredictable behavior of pywin32 on new computer

2022-10-11 Thread Tim Roberts
aware".  You can do that for one process using this code: ``` from ctypes import windll user32 = windll.user32 user32.SetProcessDPIAware() ``` Or you can use a registry hack: https://stackoverflow.com/questions/43401709/marking-your-python-program-as-high-dpi-aware-seamlessly-windows -- Tim

Re: [python-win32] Unpredictable behavior of pywin32 on new computer

2022-10-10 Thread Tim Roberts
xel coordinates you are sending to other applications will be wrong.  Go read about "high DPI aware" applications.  It's a mess. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___

Re: [python-win32] Hi

2022-07-06 Thread Tim Roberts
hoping to use? -- Tim Roberts,t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] Need a value from pywin32

2022-06-21 Thread Tim Roberts
s.WinDLL('winsta.dll')     winsta.WinStationQueryInformationW( 0, session_id, 8, ctypes.byref(Buf), BufLen, ctypes.byref(RtnLen)) If you have Visual Studio, you can try doing "link /dump /exports \windows\system32\winsta.dll" to make sure it has that entry point. -- Tim Roberts, t...@probo.com

Re: [python-win32] Need a value from pywin32

2022-06-20 Thread Tim Roberts
nted, it might be better to parse the output of "query user". -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] Package giving Error while deploying to windows container

2022-05-19 Thread Tim Roberts
and run django directly on Linux. However, this is not very good advice for an application that is invoking Microsoft Excel to do its work. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-w

Re: [python-win32] Package giving Error while deploying to windows container

2022-05-18 Thread Tim Roberts
of course, nothing that uses Win32Com can ever work on Linux. If you're trying to manipulate Excel files, there are many cross-platform libraries to do that.  If you really need to RUN Excel, then it has to be on Windows, and you have to have Excel installed. -- Tim Roberts, t...@probo.com

Re: [python-win32] Using win32com.shell to browse iphone photos | problem with pywebview

2022-05-11 Thread Tim Roberts
, then your pywebview app runs inside the browser's process, and that is a highly protected sandbox.  That's probably why you don't see external devices. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signa

Re: [python-win32] zmq under win32service

2022-03-08 Thread Tim Roberts
n you will be terminated. So, if you're using the sample you mentioned, the service "def main(self):" will need to launch a thread to do your listening. You will also need to have your thread check the "stop_request" flag, so you can cleanly exit when the service is termi

Re: [python-win32] WM_MOUSEWHEEL It only works in one window.

2022-02-16 Thread Tim Roberts
dows do not get them unless they have captured the mouse. So, please tells us what you are trying to achieve (not how you are trying to do it), and perhaps someone can advise you. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryp

Re: [python-win32] Run solidworks macro from python.

2022-02-15 Thread Tim Roberts
documentation, there has to be a command to run a named VBA script.  That's what you need to find.  The key is that this is not Python related.  You're just controlling their COM server, so you need to find the right method in the right interface in their object model. -- Tim Roberts, t

Re: [python-win32] Run solidworks macro from python.

2022-02-10 Thread Tim Roberts
r own object model. There’s no “general rule” that applies to all COM servers. You HAVE to go through the documentation for THAT product, or at least look at some examples. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ pyth

Re: [python-win32] Run solidworks macro from python.

2022-02-10 Thread Tim Roberts
t work"?  Do you get an error? Does it crash? Have you read the documentation for the SolidWorks API?  As I read the documentation, the API for running a script is called RunScript, not Run. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s

Re: [python-win32] pywintypes.com_error with adodbapi

2022-01-23 Thread Tim Roberts
were you connecting to?  The error is saying there was no driver for that database.  Note that if you are running a 64-bit Python, you must have a 64-bit ODBC driver for your database. -- Tim Roberts,t...@probo.com Providenza & Boekelheide,

Re: [python-win32] Outlook Add-In Demo Question ... A runtime error occurred during the loading of the com add-in

2021-12-09 Thread Tim Roberts
Is this the desktop versions or the Office 365 versions?  There are differences. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list python-win32@python

Re: [python-win32] Outlook Add-In Demo Question ... A runtime error occurred during the loading of the com add-in

2021-12-08 Thread Tim Roberts
instance. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] Clipboard Documentation

2021-12-01 Thread Tim Roberts
handle of the text box that has your text, you can send a WM_COPY message to it.  With the standard controls, that tells it to do a "copy" operation with the currently selected text. -- Tim Roberts, t...@probo.com Providenza & Bo

Re: [python-win32] Clipboard Documentation

2021-11-29 Thread Tim Roberts
-respected `pyperclip` module. You can install it with pip.  The Win32 clipboard APIs are a pain to work with, and of course don't work at all on other systems. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signa

Re: [python-win32] mail Sensitivity doesn't work as expected(can not set the sensitivity label)

2021-11-17 Thread Tim Roberts
tional add-ons that change this behavior, but there is nothing you can do about that with COM. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list py

Re: [python-win32] Issue with PythonCOM - Application.Run does not work for Access.Application

2021-09-17 Thread Tim Roberts
if that makes a difference? Have you tried using "win32com.client.gencache.EnsureDispatch" instead of simple "Dispatch"?  That way, it generates and caches a wrapper file.  It might be possible to peek in the generated file to see if the wrappers look any different.

Re: [python-win32] pywintypes.error: (5, 'OpenEventLogW', 'Access is denied.')

2021-09-15 Thread Tim Roberts
. https://docs.microsoft.com/en-us/archive/blogs/janelewis/giving-non-administrators-permission-to-read-event-logs-windows-2003-and-windows-2008 If you bring up the Event Viewer application ("eventvwr"), under Action, there's a "Connect to Another Computer" option.  Does that

Re: [python-win32] windows images on clipboard

2021-08-12 Thread Tim Roberts
ically speaking you can put arbitrary binary data into the clipboard, but other graphics applications will not be able to read it.  When they look for image data, they look for format CF_DIB, and that means a .BMP. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Desc

Re: [python-win32] Issue with monitor off

2021-06-10 Thread Tim Roberts
not only goin off state but the machine is also going sleep mode . My question is : Is there any way to prevent machine going to sleep ? The only thing i need is to turn monitor off :) The operating system can do this for you automatically, in the "Power & Sleep" control panel page.

Re: [python-win32] Using win32gui.FindWindow() results in black or white screen

2021-06-03 Thread Tim Roberts
. That offscreen region is then used as a texture surface which the GPU's 3D engine renders onto the visible screen.  The application window remains a solid color, which is used as a chromakey (like a "green screen") to allow menus to be easily drawn on top. -- Tim Roberts, t...@probo.com

Re: [python-win32] Does it support the 64-bit Excel

2021-04-23 Thread Tim Roberts
te it on Github repository. Quite a lot.  Did you Google for it?  It's on the first page of results.  http://timgolden.me.uk/pywin32-docs/contents.html -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list

Re: [python-win32] error 1: incorrect function when starting service python

2021-03-30 Thread Tim Roberts
repository.  You need to find another way to handle that. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list python-win32@python.org https://mail.python.

Re: [python-win32] win32com.client.WithEvents fails when running as a Windows service

2021-03-06 Thread Tim Roberts
1D3-8562-00105A3E017Bx0x1x58.py", > line 19507, in __init__ > cookie=cp.Advise(win32com.server.util.wrap(self, > usePolicy=EventHandlerPolicy)) > pywintypes.com_error: (-2147024891, 'Access is denied.', None, None) Do you have your service configured to run as your user?

Re: [python-win32] Bug When Reading In PSTs

2021-02-18 Thread Tim Roberts
not impossible that Outlook adds line for export, but that it's not actually present in the message text. Outlook takes liberties with message content that it probably shouldn't. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signa

Re: [python-win32] Bug When Reading In PSTs

2021-02-17 Thread Tim Roberts
same result if you called this method from C#. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] Opening existing memory mapped files with pywin32

2021-02-16 Thread Tim Roberts
should be able to read() the whole thing, do .decode(‘utf-8’) and pass the result to a JSON decoder. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] Opening existing memory mapped files with pywin32

2021-02-16 Thread Tim Roberts
the original message.  He is a relative beginner, just trying to do a simple file mapping. Based on his description, mmap should be able to do what he needs. I'm willing to be proven wrong, but I'm afraid you may be sending him on an unnecessary wild goose chase. -- Tim Roberts, t...@probo.com

Re: [python-win32] Opening existing memory mapped files with pywin32

2021-02-16 Thread Tim Roberts
0, access=mmap.ACCESS_READ ) That maps the whole file, and len(data) will tell you how large it is. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] DeviceIOControl calls respond with parameter incorrect

2021-02-08 Thread Tim Roberts
ceIoControl(hDisk,VC_IOCTL_GET_VOLUME_PROPERTIES,b'0x00' + > b'x05x00x00x00' + b'x00' * 702),65536) The first b’0x00’ is wrong; the first byte of the struct needs to be 5. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailin

Re: [python-win32] Error: VARIANT Type is unknown

2021-01-26 Thread Tim Roberts
that!  If it doesn't ask for a variant, then you don't deliver a variant.  Did you try just passing a string, as Mark suggested? -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-w

Re: [python-win32] Basic question about pywin32, does it work with 64 bit versions of O365?

2021-01-21 Thread Tim Roberts
and 64-bit Pythons.) However, the Office applications are out-of-process servers, so there’s a proxy in the middle, and that should let it work. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-

Re: [python-win32] how to code pywin32 run existing window task scheduler?

2021-01-14 Thread Tim Roberts
e already using them. ;) > I have tried already but error > That’s 0x80070005, which is ERROR_ACCESS_DENIED. Have you tried running this from an elevated process? — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32

Re: [python-win32] Use TPM from Crypto API

2020-11-22 Thread Tim Roberts
u have some ideas in mind to reach my goal ? The APIs from ncrypt.dll are not, as of yet, exposed in pywin32. You can certainly use ctypes to access them. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-wi

Re: [python-win32] Server Exectuion Failed

2020-11-12 Thread Tim Roberts
se the process after I am done with my object? It’s up to the the application. Out-of-process servers often provide a “close” or “exit” method to tell them to clean up. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ pyth

Re: [python-win32] Using python to create outlook rules - comtypes (working) vs. pywin32 (not working)

2020-10-30 Thread Tim Roberts
-using-python-to-create-o This is not Visual Basic.  The following statement does nothing in Python: |oFromCondition.Recipients.ResolveAll| If you want the method to be called, you have to call it: |oFromCondition.Recipients.ResolveAll()| -- Tim Roberts, t...@probo.com Providenza & Boekelh

Re: [python-win32] Strange issues when using pywin32 to develop solidworks

2020-10-07 Thread Tim Roberts
lity() ActiveDoc is a property, and so should not need parens. > Running this code and vscode says: > > line 15, in > swModel.AddComponents3(vtName,vtTrans,vtCoordName) > TypeError: 'NoneType' object is not callable > If I code it like this 'swModel.AddComponents3' then it

Re: [python-win32] AES based win32crypt lib for python3

2020-10-07 Thread Tim Roberts
ure call into the Windows LSA (Local Security Authority) to get access to the login credentials through an undocumented internal function. You can certainly find AES encryption for Python, but it’s not going to use the login credentials. — Tim Roberts, t...@probo.com

Re: [python-win32] Any update on this issue? https://github.com/mhammond/pywin32/issues/1568

2020-09-24 Thread Tim Roberts
ill have Excel installed? Are you quite sure it’s a 64-bit Excel? — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME cryptographic signature ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] how to use win32process.CreateRemoteThread

2020-09-11 Thread Tim Roberts
be part of the other process. If you want to do threading in Python, use the ’thread’ or ’threading’ modules. Don’t use win32process for that. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@

Re: [python-win32] pywintypes.com_error: (-2147221005, 'Invalid class string', None, None)

2020-09-09 Thread Tim Roberts
C installation, or you need the 64-bit Python. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] pywintypes.com_error: (-2147221005, 'Invalid class string', None, None)

2020-09-08 Thread Tim Roberts
to determine. If a company wants to support both 32-bit and 64-bit processes, then it has to install two different COM servers.  I suggest you describe your problem to the QuickOPC folks; they would know right away if this were the issue. -- Tim Roberts, t...@probo.com Providenza & Boekelh

Re: [python-win32] pywintypes.com_error: (-2147221005, 'Invalid class string', None, None)

2020-09-08 Thread Tim Roberts
the 32-bit Python, instead of the 64-bit Python? -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mai

Re: [python-win32] Licensing requirement for usage of win32com APIs through python package (pywin32)

2020-08-02 Thread Tim Roberts
How does a Microsoft license get involved? I think you’re worrying more than you need to here. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] Pythonwin.exe - trouble on the starting line

2020-07-20 Thread Tim Roberts
(the two libraries started at pretty much the same time), and wxPython has the advantage of being cross-platform. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mai

Re: [python-win32] How to install pywin32 for Text only/TTY, excluding all GUI components

2020-05-26 Thread Tim Roberts
in32 that are actually required by the application. If you’re shipping your application via pip on WIndows, then virtually everyone will already have pywin32. It is a critical component. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. __

Re: [python-win32] python-win32 Digest, Vol 205, Issue 5

2020-05-25 Thread Tim Roberts
needed. When I say “package”, I mean an application package that you want to distribute, created by something like pyinstaller. It will only include the components your application needs. I just don’t see that there is anything to gain in making such a substantial change.

Re: [python-win32] How to install pywin32 for Text only/TTY, excluding all GUI components

2020-05-24 Thread Tim Roberts
ents, e.g. MFC.dll. > What are your thoughts? What is the point? Installing a package does not mean you are required to use all of it. If you ship a package that doesn’t need the UI components, then your package will not include the components. — Tim Roberts, t...@probo.com Providen

Re: [python-win32] [win32com] Meaning of "TypeError: Only com_record objects can be used as records"?

2020-04-30 Thread Tim Roberts
the old mailing list threads I found. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] [win32com] Meaning of "TypeError: Only com_record objects can be used as records"?

2020-04-28 Thread Tim Roberts
ric structs like that are not in those rules. Some people get the idea that anything they can express in C++ can be shoved in a COM interface, but it ain’t so. You should be able to add a GUID attribute to the IDL: [ uuid(12345678-1234-1234-1234-123456789ABC) ] typedef struct SoftwareInfo { … } Softw

Re: [python-win32] How to change print copies

2020-04-23 Thread Tim Roberts
le copies on its own. Have you seen a multi-copy setting work using the native driver? — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] VT_DECIMAL variant

2020-04-15 Thread Tim Roberts
it by hand.  I just don't know the recipe.  If Tim Golden is listening, perhaps he can point us to a reference. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mai

Re: [python-win32] VT_DECIMAL variant

2020-04-15 Thread Tim Roberts
anding in the pythoncom code. CURRENCY goes back to the days of Visual Basic 6, whereas DECIMAL is much more recent.  It may be appropriate to file a bug report. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic

Re: [python-win32] VT_DECIMAL variant

2020-04-15 Thread Tim Roberts
at you should use. In order to use VT_DECIMAL, then you probably can’t use automatic translation. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] User login details when running a service

2020-04-11 Thread Tim Roberts
There is a WMI query that can return the name of all logged in users: https://stackoverflow.com/questions/5218778/how-do-i-get-the-currently-logged-username-from-a-windows-service-in-net <https://stackoverflow.com/questions/5218778/how-do-i-get-the-currently-logged-username-from-a-windows-servi

Re: [python-win32] pure python way to open a file with write deny for others

2020-03-06 Thread Tim Roberts
atively, and perhaps more hacky, you can use subprocess to copy the file to a safe temporary name. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list

Re: [python-win32] How to set value with PyIPropertyStore

2019-11-14 Thread Tim Roberts
ia files, but I seriously doubt they will be to MODIFY media files. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] How to set value with PyIPropertyStore

2019-11-10 Thread Tim Roberts
ring', None, None) That’s correct. “” is not a valid class string. SHGetPropertyStoreFromParsingName returns a COM interface, and you have to tell it what interface you want. It is usually IPropertyStore. What are you trying to do here? Are you porting some C++ code you found into Pyth

Re: [python-win32] How to set value with PyIPropertyStore

2019-11-07 Thread Tim Roberts
at I had to figure this out twice today. dateShifted = propsys.PROPVARIANTType(mDate+shift_time.timedelta_obj, pythoncom.VT_DATE) The PROPVARIANTType function returns a PyPROPVARIANT object. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. __

Re: [python-win32] How to set value with PyIPropertyStore

2019-11-07 Thread Tim Roberts
(VIDEO_DATE_ENCODED, dateShifted) I found it.  Try   dateShifted = propsys.PyPROPVARIANT(mData + shift_time.timedelta_obj, pythoncom.VT_DATE) -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signa

Re: [python-win32] NotifyAddrChange

2019-11-05 Thread Tim Roberts
jects/iphelpers/files/> — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] passing array by reference (3)

2019-10-27 Thread Tim Roberts
, thank you! What DID happen? You don’t have a newline at the very end of the string. CATIA might need that. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/m

Re: [python-win32] How to set value with PyIPropertyStore

2019-10-14 Thread Tim Roberts
get an error? -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] Word Application saving to PDF

2019-10-09 Thread Tim Roberts
'Command failed', 'wdmain11.chm', 36966, -2146824090), None) Did you do any web searching for this? -2146824090 is 0x80A1066, which is a security issue. Do you have permission to write into that directory? Are you able to do this same action if you do it by hand? —

Re: [python-win32] Calling Methods of an object returned by an COMObject method

2019-09-20 Thread Tim Roberts
round as a COM server, so there’s no visible change when you quiet. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] Dispatch command hangs

2019-08-15 Thread Tim Roberts
t-of-process server, so you’re receiving requests from other processes? If so, then I think you’re seeing RPC (Remote Procedure Call), which marshals the parameters back and forth, and I believe those are all first-come first-served. — Tim Roberts, t...@probo.com Providenza &

Re: [python-win32] Dispatch command hangs

2019-08-15 Thread Tim Roberts
ee if that helps. But even then, you bang up against the Python interpreter lock, which only allows the interpreter to handle one thread at a time. I wouldn’t think you’d have to wait for the whole set of object requests to drain, but threading in Python is always tricky. — Tim Roberts

Re: [python-win32] DoAction problem

2019-07-28 Thread Tim Roberts
oshop questions. Adobe has documentation on the Photoshop APIs, and they have their own user forums. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] DoAction problem

2019-07-25 Thread Tim Roberts
onvert TIF to JPG, you certainly do not need to launch the Photoshop behemoth for that. Just use pip to install "pillow", the Python Imaging Library, and all you need is this:     from PIL import Image     Image.open('myfile.tif').save('myfile.jpg') -- Tim Roberts, t...@probo.com Prov

Re: [python-win32] DoAction problem

2019-07-25 Thread Tim Roberts
s, I strongly suggest you take a look at the ImageMagick package.  It is an incredible powerful photo manipulation tool that is all driven from the command line.  It can be a bit tricky to set up the command lines, but once you do, it works the same way, time after time. -- Tim Robe

Re: [python-win32] Problem reading a shortcut (.lnk) with cPython 3.7 (32 bit)

2019-06-18 Thread Tim Roberts
-bit Python on a 64-bit system?  Theoretically, you should be able to use CLSID_ShellLink from either one, but I'm trying to narrow things down.  Tim's code works fine for me with Python 3.7.2 (64 bit) on Windows 10. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime

Re: [python-win32] Retrieve Windows Notifications With pywin32

2019-06-06 Thread Tim Roberts
s to deal with. There are many things that would be inappropriate for you to dismiss. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.org https://mail.python.org/mailman/listinfo/python-win32

Re: [python-win32] Retrieve Windows Notifications With pywin32

2019-06-02 Thread Tim Roberts
cations are there for a reason, and they are expected to be handled by a human user. What kind of notifications are you trying to dismiss? — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. ___ python-win32 mailing list python-win32@python.

Re: [python-win32] connecting to labview executable

2019-05-12 Thread Tim Roberts
ay, LabView can do socket comunication so I think this is the way do > go rather than reading LabView controls via pywin32. Agreed. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME cryptographic signature ___

Re: [python-win32] connecting to labview executable

2019-05-12 Thread Tim Roberts
lready running? If so, then all you should have to do is use os.spawn or subprocess.Popen to launch the executable. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME cryptographic signature ___ python-win32 ma

Re: [python-win32] getvireference issue

2019-05-09 Thread Tim Roberts
LabView.Application") > VI = labview.getvireference(r'Controller.vi') > I get the following error: > > AttributeError: ' instance at 0x43780248>' object has no attribute 'getvireference' The actual spelling is GetVIReference. Does that work? — Tim Roberts

Re: [python-win32] hook the left mouse button down event on any window

2019-03-30 Thread Tim Roberts
okMessage call and when the function returns. The right answer is to use a package like pyHook to install a global hook. This is exactly what it is for. https://stackoverflow.com/questions/165495/detecting-mouse-clicks-in-windows-using-python <https://stackoverflow.com/questions/165495/detec

Re: [python-win32] hook the left mouse button down event on any window

2019-03-29 Thread Tim Roberts
exits, the window object is deleted, and the hook is released. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list python-win32@python.org https://mail

Re: [python-win32] ExportAsFixedFormat's ValueError

2019-03-27 Thread Tim Roberts
essage?  Did it tell you which argument was wrong?  What, exactly, is "output"? It would be helpful to see the code leading up to this as well. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature

Re: [python-win32] chapter 5 : implementing com objects with python

2019-03-26 Thread Tim Roberts
whether Office 365 is a 32-bit app or a 64-bit app, but your version of Python must match. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptographic Signature ___ python-win32 mailing list py

Re: [python-win32] How to get target of folder shortcuts

2019-03-18 Thread Tim Roberts
es? Your code works for me, although the SFGAO_FOLDER bit is not set for my folder shortcut.  If you do a "dir" of the folder where the link lives, what do you see?  Is it actually a .lnk file of about a kilobyte? There are no DOS attributes on my folder shortcut.  What do you see

Re: [python-win32] Performing ReplyAll to outlook email message

2019-03-15 Thread Tim Roberts
have to do it all "the hard way". Create a new message, copy the Receipts list into the new message, set your body, send it.  Not a lot of code, but it's a little tedious. -- Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime.p7s Description: S/MIME Cryptogra

Re: [python-win32] COM Photoshop - Exception occurred

2019-03-09 Thread Tim Roberts
ent versions of Photoshop? Could the “slct” action refer to a plugin that isn’t present on your Windows 10 system? The key point is that this is almost certainly going to end up being a Photoshop issue, not a Python issue. — Tim Roberts, t...@probo.com Providenza & Boekelheide, Inc. smime

  1   2   3   4   5   6   7   8   9   10   >