[python-win32] Find Target
Tim Roberts
timr at probo.com
Thu Apr 3 18:42:08 CEST 2008
Rickey, Kyle W wrote:
>
> I am trying to figure out how to show a specified file in explorer. I
> know I can call os.startfile(directory) to show the containing
> directory, but I would like the file to be selected also. Is there an
> API call that windows makes to do this?
>
>
>
> For example, right click on a shortcut and go to properties, then
> click on the ‘Find Target’ button. Any ideas?
>
You're talking about controlling the UI here. You could do that by
finding the Explorer window, trolling through to find the list control,
find the entry, simulate right-click, etc., but it would be an
undocumented pain in the rear.
However, everything that's in those dialogs is exposed through the shell
API. Why don't you just display the dialog yourself?
--
Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.
More information about the python-win32
mailing list