LocustHorde
LocustHorde

Reputation: 11

Open a folder with position specified from command prompt

I am making a small utility batch file.

To Open a folder minimized, I need to do:

start /MIN %SystemRoot%\explorer.exe "D:\backup"

I have few other folders to open and I want to open it for copy / paste purpose and for usability reasons (my own preference) I want the source folder to be on right and destination folder to be on left. It always opens up in the other order.

So I want to specify the witdh / height of the folder plus xy position for it to open on my desktop. Is it even possible to do this? If not, what is the next best thing?

I am making a small batch file that I can use to speed backup server stuff without repeating mundane tasks everytime, one or two folders this way is okay but I have quite a few.

Many thanks.

ps: I tried to login with myopenid and it said error, end point not found. grrrrr.

Upvotes: 1

Views: 4879

Answers (1)

Ryan Bemrose
Ryan Bemrose

Reputation: 9266

There is no way to set a non-maximized explorer window's location on the screen from a batch script.

You can do this by writing a C/C++ program which moves the windows via Win32 (eg: FindWindowEx, SendMessage(WM_SIZE)) and call that program from your script.

Upvotes: 2

Related Questions