Shortcut locations

  • Thread starter Thread starter HMS Surprise
  • Start date Start date
H

HMS Surprise

Is there a file or registry entry that specifies where shortcuts are
placed?

I use AutoIt to load several apps and programs like WinMerge, WinObj,
MySQL, etc on servers on a regular basis. This creates about 6
shortcuts. Additionally there are 4 more shortcuts that I copy from a
folder to the desktop. After the shortcuts are placed on the desktop I
would like to set their locations via a script.


Thanks,

jh
 
Should have also stated that I will need to edit the parameter that
controls Auto Arrange Icons.

jh
 
Tricky...

Desktop view settings are saved here:

HKCU\Software\Microsoft\Windows\Shell\Bags\1\Desktop

If icons have been manually positioned, the layout is stored in this value:

ItemPos1024x768(1) (the name is dependent on your screen resolution)

Auto Arrange is controlled by a bit in the 'FFlags' value. Here are its
possible settings:

http://msdn2.microsoft.com/en-us/library/ms649291.aspx

The other problem is that this key is only read at shell startup (logon) &
written at shell shutdown. So to modify the values & have them take effect
in your current session, you need to end the shell instance of Explorer,
make your changes, then restart Explorer.

All in all, you really might want to consider adding a folder as a toolbar
to your taskbar & placing the shortcuts in there :)
 
Tricky...

Desktop view settings are saved here:

HKCU\Software\Microsoft\Windows\Shell\Bags\1\Desktop

If icons have been manually positioned, the layout is stored in this value:

ItemPos1024x768(1) (the name is dependent on your screen resolution)

Auto Arrange is controlled by a bit in the 'FFlags' value. Here are its
possible settings:

http://msdn2.microsoft.com/en-us/library/ms649291.aspx

The other problem is that this key is only read at shell startup (logon) &
written at shell shutdown. So to modify the values & have them take effect
in your current session, you need to end the shell instance of Explorer,
make your changes, then restart Explorer.

All in all, you really might want to consider adding a folder as a toolbar
to your taskbar & placing the shortcuts in there :)

--
Good Luck,

Keith
Microsoft MVP [Windows XP Shell/User]


Should have also stated that I will need to edit the parameter that
controls Auto Arrange Icons.

Thanks Keith,

May I ask how one shuts down an instance of explorer w/o shutting down
Windows?
 
Tricky...
Desktop view settings are saved here:

If icons have been manually positioned, the layout is stored in this value:
ItemPos1024x768(1) (the name is dependent on your screen resolution)
Auto Arrange is controlled by a bit in the 'FFlags' value. Here are its
possible settings:

The other problem is that this key is only read at shell startup (logon) &
written at shell shutdown. So to modify the values & have them take effect
in your current session, you need to end the shell instance of Explorer,
make your changes, then restart Explorer.
All in all, you really might want to consider adding a folder as a toolbar
to your taskbar & placing the shortcuts in there :)
Keith
Microsoft MVP [Windows XP Shell/User]

Thanks Keith,

May I ask how one shuts down an instance of explorer w/o shutting down
Windows?

I should have asked how to do it programmatically. I will try taskkill
and then try a restart via a dos window.
 
To kill explorer and restart it.

Open the Task Manager...
Ctrl + Shift + Escape | Click on the Processes tab | Locate and highlight
explorer.exe | Right click explorer.exe | Click End Process | Click
Yes to the Task Manager Warning that pops up | Click File on the Toolbar |
Click New Task (Run...) | Type in: explorer | Click OK

End Process on explorer.exe will make your Desktop, Taskbar and all programs
disappear. This can be startling. Restarting explorer will bring
everything back.

This can fix/restore/reinitialize/refresh a lot of things.

Like changes in HKCU. If registry changes in the HKLM need to be refreshed
you have to reboot the machine.

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
HMS Surprise said:
Tricky...

Desktop view settings are saved here:

HKCU\Software\Microsoft\Windows\Shell\Bags\1\Desktop

If icons have been manually positioned, the layout is stored in this
value:

ItemPos1024x768(1) (the name is dependent on your screen
resolution)

Auto Arrange is controlled by a bit in the 'FFlags' value. Here are its
possible settings:

http://msdn2.microsoft.com/en-us/library/ms649291.aspx

The other problem is that this key is only read at shell startup (logon)
& written at shell shutdown. So to modify the values & have them take
effect in your current session, you need to end the shell instance of
Explorer, make your changes, then restart Explorer.

All in all, you really might want to consider adding a folder as a
toolbar to your taskbar & placing the shortcuts in there :)

--
Good Luck,

Keith
Microsoft MVP [Windows XP Shell/User]


Should have also stated that I will need to edit the parameter that
controls Auto Arrange Icons.

Thanks Keith,

May I ask how one shuts down an instance of explorer w/o shutting down
Windows?
 
MHS,

Open Task manage, highlight Explorer & END TASK it. The start new task
'explorer.exe'

--
Newbie Coder
(It's just a name)

HMS Surprise said:
Tricky...
Desktop view settings are saved here:

If icons have been manually positioned, the layout is stored in this
value:
ItemPos1024x768(1) (the name is dependent on your screen
resolution)
Auto Arrange is controlled by a bit in the 'FFlags' value. Here are its
possible settings:

The other problem is that this key is only read at shell startup (logon) &
written at shell shutdown. So to modify the values & have them take effect
in your current session, you need to end the shell instance of Explorer,
make your changes, then restart Explorer.
All in all, you really might want to consider adding a folder as a toolbar
to your taskbar & placing the shortcuts in there :)
Keith
Microsoft MVP [Windows XP Shell/User]
Should have also stated that I will need to edit the parameter that
controls Auto Arrange Icons.

Thanks Keith,

May I ask how one shuts down an instance of explorer w/o shutting down
Windows?

I should have asked how to do it programmatically. I will try taskkill
and then try a restart via a dos window.
 
--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

Thanks for posting again.

Perhaps you missed my PS I was a few minutes in adding). I need to
accomplish this shutdown and restart via a script.

jh
 
I have NFI how to kill explorer.exe other than the way that I explained.

taskkill /im explorer.exe wants to shutdown Windows and net stop is only
for services, which explorer.exe is not. taskkill /im explorer.exe acts
like Start | Turn Off Computer.

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
 
For Each Process in GetObject("winmgmts:"). _
ExecQuery ("select * from Win32_Process where name='explorer.exe'")
Process.terminate(0)
Next
 
[HMS Surprise]s message :
Thanks Keith,

May I ask how one shuts down an instance of explorer w/o shutting down
Windows?


I think you can use dllcall(s) to refresh the explorer view. Ask in AutoIt forums.

If you are happy with restarting explorer then(untested)-

ProcessClose("explorer.exe")
ProcessWaitClose("explorer.exe",12)
Run("explorer.exe")


Good Luck, Ayush.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top