VB Script for Pinned Site Shortcuts? RRS feed

  • Question

  • I have tried everything i can think of to either convert my old shortcut script or create a new one, so that i can make Pinned Site Shortcuts (.website) for the desktop of Windows 7 users. I have seen some scripts that place them on the Start Screen of Windows 8, but that is not exactly what I need.

    Here is the current script I am using

    Set wsc = WScript.CreateObject("WScript.Shell")
    Set lnk1 = wsc.CreateShortcut(wsc.SpecialFolders("desktop") & "\.LNK")
    Set lnk2 = wsc.CreateShortcut(wsc.SpecialFolders("desktop") & "\.LNK")
    Set lnk3 = wsc.CreateShortcut(wsc.SpecialFolders("desktop") & "\.LNK")
    lnk1.targetpath = ""
    lnk1.description = ""
    lnk2.targetpath = ""
    lnk2.description = ""
    lnk3.targetpath = ""
    lnk3.description = ""

    • Moved by Bill_Stewart Thursday, January 2, 2014 7:22 PM Abandoned
    Friday, November 1, 2013 2:29 PM

All replies

  • .website shortcuts appear to be INI-style text files similar to .url shortcuts, but containing a lot more information.

    I searched around a bit, and even on MSDN, did not find any way to programatically create a new .website file.  Microsoft's documentation for deploying pinned sites says to just create it manually from IE (by dragging the site's icon somewhere), then deploying the resulting .website file.

    Unfortunately, the extra fields in the .website files don't always have terribly useful names (Prop5=3,0 , Prop9=19,0, etc), so it's hard to say whether you'd be able to reliably build these files yourself.  You could try creating pinned sites manually and comparing the contents of the .website files; perhaps you might find out what they mean, and what they should be set to by your script.

    Here are the .url and .website versions of this forum thread, for example:

    # VB Script for Pinned Site Shortcuts.url
    # VB Script for Pinned Site
    Prop4=31,VB Script for Pinned Site Shortcuts?

    Friday, November 1, 2013 3:13 PM
  • I see what you mean. The file type is fairly new, so there just isn't a lot of documentation out there. I will keep working on it. Your example was incredibly helpful, thanks!
    Friday, November 1, 2013 4:04 PM