{"id":6,"date":"2006-06-13T12:11:42","date_gmt":"2006-06-13T06:41:42","guid":{"rendered":"http:\/\/198.58.113.91\/blog\/create-an-internet-shortcut-using-batch-file\/"},"modified":"2019-06-24T17:49:47","modified_gmt":"2019-06-24T17:49:47","slug":"create-an-internet-shortcut-using-batch-file","status":"publish","type":"post","link":"https:\/\/www.winhelponline.com\/blog\/create-an-internet-shortcut-using-batch-file\/","title":{"rendered":"Create an Internet Shortcut Using Batch File"},"content":{"rendered":"<p><strong>Q:<\/strong>\u00a0 Is there a way to create a batch file which would put a desktop icon onto the desktop which invokes an HTML page in a web browser and change the associated icon for that particular desktop item, all in one batch file? Thanks<\/p>\n<p><strong>A:<\/strong> Yes. This is possible. Here are some examples:<\/p>\n<pre>echo [InternetShortcut] &gt;\"%userprofile%\\desktop\\localpage.url\"\r\necho URL=C:\\myfile.htm &gt;&gt;\"%userprofile%\\desktop\\localpage.url\"\r\necho IconFile=C:\\icons\\favicon.ico &gt;&gt;\"%userprofile%\\desktop\\localpage.url\"\r\necho IconIndex=0 &gt;&gt;\"%userprofile%\\desktop\\localpage.url\"<\/pre>\n<pre>echo [InternetShortcut] &gt;\"%userprofile%\\desktop\\google.url\"\r\necho URL=http:\/\/www.google.com\/ &gt;&gt;\"%userprofile%\\desktop\\google.url\"\r\necho IconFile=e:\\icons\\google.ico\u00a0\u00a0&gt;&gt;\"%userprofile%\\desktop\\google.url\"\r\necho IconIndex=0 &gt;&gt;\"%userprofile%\\desktop\\google.url\"<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Q:\u00a0 Is there a way to create a batch file which would put a desktop icon onto the desktop which invokes an HTML page in a web browser and change the associated icon for that particular desktop item, all in one batch file? Thanks A: Yes. This is possible. Here are some examples: echo [InternetShortcut] &#8230; <a title=\"Create an Internet Shortcut Using Batch File\" class=\"read-more\" href=\"https:\/\/www.winhelponline.com\/blog\/create-an-internet-shortcut-using-batch-file\/\" aria-label=\"Read more about Create an Internet Shortcut Using Batch File\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[2],"tags":[],"class_list":["post-6","post","type-post","status-publish","format-standard","hentry","category-general"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack-related-posts":[{"id":1097,"url":"https:\/\/www.winhelponline.com\/blog\/backup-pinned-taskbar-shortcuts-restore\/","url_meta":{"origin":6,"position":0},"title":"How to Backup and Restore Pinned Taskbar Shortcuts in Windows 10","author":"Ramesh","date":"October 2, 2010","format":false,"excerpt":"When you install Windows on a new computer, customizing Windows takes a lot of time and effort. One such thing is the taskbar. You may have to redo the procedure of pinning the applications which you frequently use. If you're planning to move to a new Windows PC or a\u2026","rel":"","context":"In &quot;Windows&quot;","block_context":{"text":"Windows","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/"},"img":{"alt_text":"taskband registry key","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2010\/10\/w10-taskband-key.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2010\/10\/w10-taskband-key.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2010\/10\/w10-taskband-key.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2010\/10\/w10-taskband-key.png?resize=700%2C400&ssl=1 2x"},"classes":[]},{"id":26716,"url":"https:\/\/www.winhelponline.com\/blog\/duplicate-desktop-icons-in-windows\/","url_meta":{"origin":6,"position":1},"title":"Fix for Duplicate Desktop Icons in Windows","author":"Ramesh","date":"May 29, 2022","format":false,"excerpt":"Every time when you place a file or a shortcut on your Desktop, you may get 2 identical icons. If one icon is deleted, the other icon will also be removed if you refresh the Desktop. The path for both icons would be the same. You may be wondering what\u2026","rel":"","context":"In &quot;Windows&quot;","block_context":{"text":"Windows","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":46006,"url":"https:\/\/www.winhelponline.com\/blog\/shellnew-only-folder-listed\/","url_meta":{"origin":6,"position":2},"title":"New Menu Shows Only &#8220;Folder&#8221; in the Desktop Context Menu","author":"Ramesh","date":"May 14, 2023","format":false,"excerpt":"When you right-click on the desktop and click New, the New menu may only show the \"Folder\" entry. The other options, such as \"Shortcut,\" \"Text document,\" and \"Bitmap image,\" may be missing in the New menu. It's not typical for the Desktop folder to show only the \"Folder\" entry, and\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"new menu lists only folder","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/05\/new-menu-lists-only-folder.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":1592,"url":"https:\/\/www.winhelponline.com\/blog\/windows-10-shell-folders-paths-defaults-restore\/","url_meta":{"origin":6,"position":3},"title":"Windows 10\/11 User Shell Folders Restore Default Paths","author":"Ramesh","date":"February 7, 2016","format":false,"excerpt":"This post provides you with the list of User Shell Folders in Windows 10\/11 and their default paths. If you've moved a shell folder earlier, you can restore it to the default location via the folder properties Location tab in most cases. However, there are situations where the Location tab\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"user shell folders - local machine","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2016\/02\/w10-11-user-shell-folders-system-registry-full.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2016\/02\/w10-11-user-shell-folders-system-registry-full.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2016\/02\/w10-11-user-shell-folders-system-registry-full.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2016\/02\/w10-11-user-shell-folders-system-registry-full.png?resize=700%2C400&ssl=1 2x"},"classes":[]},{"id":50378,"url":"https:\/\/www.winhelponline.com\/blog\/shell-folder-wrong-name\/","url_meta":{"origin":6,"position":4},"title":"Fix: Shell Folder Shows with an Incorrect Name","author":"Ramesh","date":"May 31, 2023","format":false,"excerpt":"After moving the user shell folders, such as Desktop, Download, Documents, Pictures, Music, or Videos, incorrectly, one of your shell folders may show up with a different name. For example, the \"Documents\" folder may show up as \"Downloads\", or \"Desktop\" may appear as \"Downloads\". However, the folder name may show\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"desktop shell folder renamed - localizedresourcename","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/05\/desktop-name-changed-4.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/05\/desktop-name-changed-4.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/05\/desktop-name-changed-4.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2023\/05\/desktop-name-changed-4.png?resize=700%2C400&ssl=1 2x"},"classes":[]},{"id":1608,"url":"https:\/\/www.winhelponline.com\/blog\/shell-folders-merged-music-videos-same-folder\/","url_meta":{"origin":6,"position":5},"title":"[Fix] Music, Pictures, Videos or Downloads Folders Merged Accidentally and Point to the Same Location","author":"Ramesh","date":"February 10, 2016","format":false,"excerpt":"This post talks about a problem where two special folders such as Music, Pictures, Videos, or Documents get merged or combined and point to the same folder. Because the special or shell folders are merged, they show up with the same name but different icons. Additionally, restoring the default location\u2026","rel":"","context":"In &quot;Windows 10&quot;","block_context":{"text":"Windows 10","link":"https:\/\/www.winhelponline.com\/blog\/category\/microsoft\/windows\/windows-10\/"},"img":{"alt_text":"special folders merged in windows 10","src":"https:\/\/i0.wp.com\/www.winhelponline.com\/blog\/wp-content\/uploads\/2016\/02\/folder-merged.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]}],"_links":{"self":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/posts\/6","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/comments?post=6"}],"version-history":[{"count":0,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/posts\/6\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/media?parent=6"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/categories?post=6"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.winhelponline.com\/blog\/wp-json\/wp\/v2\/tags?post=6"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}