Determining the Most recent active window (folder) from Shortcut toolbar 
Author Message
 Determining the Most recent active window (folder) from Shortcut toolbar

I would like to make a vbs program that is always handy and for me that
means
that it should sit in my shortcut toolbar (I hope I got the terminology
right - the
section just to the right of the Start menu on my Win2K Pro system).  The
reason being that:

What this script wants to do is to rename all the files matching a certain
criterion
in the "active" folder which would be the one that was active just as I am
clicking
on the Rename.vbs file sitting in the shortcut toolbar.

Sadly, I am stumped right out of the gate because by the time I get to
set WshShell = WScript.CreateObject ("WScript.Shell")
MsgBox "Current Dir: " & WshShell.CurrentDirectory
it is already too late.
 (I get: C:\Program Files\Common Files\SYSTEM\MAPI\1033, which is itself a
little puzzling since Rename.vbs is sitting in
C:\Documents and Settings\Administrator\Application Data\Microsoft\Internet
Explorer\Quick Launch)

Is there a way to do what I'd like?
Thanks,
    Csaba Gabor



Sun, 04 Sep 2005 04:18:47 GMT  
 Determining the Most recent active window (folder) from Shortcut toolbar
  That would require that you leave wscript.exe running, wscript.shell
loaded and the script looping...not to mention the issue of finding the
active window. It might make more sense to write a script that checks
for command argument (for drag and drop functionality), leave a copy
on the Desktop, then just drop folders onto that.

--
--

Quote:
> I would like to make a vbs program that is always handy and for me that
> means
> that it should sit in my shortcut toolbar (I hope I got the terminology
> right - the
> section just to the right of the Start menu on my Win2K Pro system).  The
> reason being that:

> What this script wants to do is to rename all the files matching a certain
> criterion
> in the "active" folder which would be the one that was active just as I am
> clicking
> on the Rename.vbs file sitting in the shortcut toolbar.

> Sadly, I am stumped right out of the gate because by the time I get to
> set WshShell = WScript.CreateObject ("WScript.Shell")
> MsgBox "Current Dir: " & WshShell.CurrentDirectory
> it is already too late.
>  (I get: C:\Program Files\Common Files\SYSTEM\MAPI\1033, which is itself a
> little puzzling since Rename.vbs is sitting in
> C:\Documents and Settings\Administrator\Application

Data\Microsoft\Internet

- Show quoted text -

Quote:
> Explorer\Quick Launch)

> Is there a way to do what I'd like?
> Thanks,
>     Csaba Gabor



Sun, 04 Sep 2005 09:15:59 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Determining if a folder is a local pst folder or a imap (server folder)

2. Install/Uninstall Shortcut to and from Windows StartUp folder

3. Install/Uninstall Shortcut to and from Windows StartUp folder

4. How can I determine the Active Windows Name?

5. Determining Currently Active (topmost) window on desktop

6. API for determining the last active window

7. Folder Shortcut -vs- Application Shortcut

8. How to craeate/copy a shortcut to folder in Windows 2000

9. shortcut to open 2 Windows folders?

10. Help determining the Windows folder

11. Determining if there has been recent user activity

12. Clean out of Temp Internet , History, recent Folders

 

 
Powered by phpBB® Forum Software