Case : Pin Menu Order shortcut to the taskbar in Windows 11. Each Pc has a different link menu that identifies the pc name.
- First create each shortcut for all the Pc.
- Create new document, then paste the following script . Then save it as "Menu.bat" :
@echo off
if %computername% equ HIGH1 copy "Menu Order HIGH1.lnk" "%USERPROFILE%\Desktop\Menu Order.lnk" & copy "Menu Order HIGH1.lnk" "%AppData%\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Menu Order.lnk"
if %computername% equ HIGH2 copy "Menu Order HIGH2.lnk" "%USERPROFILE%\Desktop\Menu Order.lnk" & copy "Menu Order HIGH2.lnk" "%AppData%\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Menu Order.lnk"
if %computername% equ HIGH3 copy "Menu Order HIGH3.lnk" "%USERPROFILE%\Desktop\Menu Order.lnk" & copy "Menu Order HIGH3.lnk" "%AppData%\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Menu Order.lnk"
if %computername% equ HIGH4 copy "Menu Order HIGH4.lnk" "%USERPROFILE%\Desktop\Menu Order.lnk" & copy "Menu Order HIGH4.lnk" "%AppData%\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Menu Order.lnk"
if %computername% equ HIGH5 copy "Menu Order HIGH5.lnk" "%USERPROFILE%\Desktop\Menu Order.lnk" & copy "Menu Order HIGH5.lnk" "%AppData%\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Menu Order.lnk"
exit
if %computername% equ HIGH1 copy "Menu Order HIGH1.lnk" "%USERPROFILE%\Desktop\Menu Order.lnk" & copy "Menu Order HIGH1.lnk" "%AppData%\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Menu Order.lnk"
if %computername% equ HIGH2 copy "Menu Order HIGH2.lnk" "%USERPROFILE%\Desktop\Menu Order.lnk" & copy "Menu Order HIGH2.lnk" "%AppData%\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Menu Order.lnk"
if %computername% equ HIGH3 copy "Menu Order HIGH3.lnk" "%USERPROFILE%\Desktop\Menu Order.lnk" & copy "Menu Order HIGH3.lnk" "%AppData%\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Menu Order.lnk"
if %computername% equ HIGH4 copy "Menu Order HIGH4.lnk" "%USERPROFILE%\Desktop\Menu Order.lnk" & copy "Menu Order HIGH4.lnk" "%AppData%\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Menu Order.lnk"
if %computername% equ HIGH5 copy "Menu Order HIGH5.lnk" "%USERPROFILE%\Desktop\Menu Order.lnk" & copy "Menu Order HIGH5.lnk" "%AppData%\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Menu Order.lnk"
exit
- Boot up one of the Pc normally. Pin the shorcut manually to the taskbar.
- Export the following registry and save it as "taskbar.reg" . Then copy this reg file to Server :
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband]
- Create new document, then paste the following script . Then save it as "startup.bat" :
@echo off
regedit /s taskbar.reg
powershell set-executionpolicy remotesigned
powershell stop-process -name explorer –force
exit
regedit /s taskbar.reg
powershell set-executionpolicy remotesigned
powershell stop-process -name explorer –force
exit
- Set the menu.bat and startup.bat files to run when windows start or log on in client pc.
No comments:
Post a Comment