ISWIX, LLC View Christopher Painter's profile on LinkedIn profile for Christopher Painter at Stack Overflow, Q&A for professional and enthusiast programmers

Friday, June 8, 2007

Deploying a Vista SideBar Gadget

Bob Crawford recently asked on InstallShield Community:

Hi, we are developing a Vista application with a companion Sidebar gadget. We would like to install/uninstall the gadget along with the application. Does Installshield 2008 have this kind of support for Sidebar gadgets?

I havn't done this yet so I decided to start Googling. This interesting MSDN Lab came up:

Windows Vista: Creating a Simple Sidebar Gadget Virtual Lab

After registering you can download a PDF that walks through the process of creating a manifest for your gadget. From there it's a matter of giving the directory a name that ends with `.gadget` ( known as development packaging and seemingly implied not to be used for production ) or zipping / cabbing the directory and giving the compressed file a .gadget extension.

From there gadgets are deployed in true .NET ( and Java ) style.... XCOPY to C:\Program Files\Windows Sidebar\Gadgets. You simple create a component, add the .gadget file as the key file, set the directory and associate it to a feature.

So in short, yes InstallShield 2008 supports deploying SideBar gadgets.

4 comments:

  1. Thanks for sharing.

    However, using development deployment method, how can I put or place the Gadget automatically on the sidebar?

    Can InstallShield 2008 support this ?

    ReplyDelete
  2. So what I described only installs the gadget, it doesn't actually add it to the Sidebar.

    Best I can tell ( correct me if I'm wrong ) but there doesn't seem to be an automation interface for managing this. There is a settings.ini but that seems like it should be private storage.


    http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1759618&SiteID=1

    So assuming the above thread is correct, you'd have to shutdown sidebar, read the configuration data, apply business rules to correctly insert the new gadget, write the INI back out and start sidebar back up.

    Assuming you can get the business rules down correctly ( I can't find them documented ) then yes, InstallShield 2008 can do this.

    ReplyDelete
  3. Thanks for your advice.

    "There is a settings.ini but that seems like it should be private storage."

    Yes, as I could not locate any documentation on the setting.ini too. So, has not venture into this area yet.

    ReplyDelete
  4. Could you post a link here if you do? Thanks!

    ReplyDelete