In general, the steps for creating a gadget are:
- Create a folder named “YourGadgetName.gadget” in any of below location you prefer. (Or you can create it on any other location but for installing, you need to copy it one of the below locations).(for user gadgets)
(for global gadgets)
%SYSTEM_ROOT%\Program Files\Windows Sidebar\Gadgets (for global gadgets)
The following image shows a gadget development folder in the %USER_DATA%\Local\Microsoft\Windows Sidebar\Gadgets folder.
These practices ensure the gadget appears in the gadget picker with minimal subsequent file handling.
- Create the manifest file and save it to the development folder. For more information on the gadget manifest, see Gadgets for Windows Sidebar Manifest.
<?xml version="1.0" encoding="utf-8" ?> <gadget> <name>SDK Shell</name> <version>126.96.36.199</version> <hosts> <host name="sidebar"> <base type="HTML" apiVersion="1.0.0" src="HelloWorld.html" /> <permissions>Full</permissions> <platform minPlatformVersion="1.0" /> </host> </hosts> </gadget>
- Create the “HelloWorld.html” file and save it to the development folder.
<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=Unicode" /> </head> <body> <div id="gadgetContent"> </div> </body> </html>
- Install the gadget, if necessary.Depending on where you created your development folder, you may need to copy the folder or its content to one of the two previously identified Sidebar system folders. Alternatively, you may want to package the gadget for general distribution and test the gadget installation process. For more information on installing and updating a gadget, see Gadgets for Windows Sidebar Updating and Refreshing.
- Test the gadget and make revisions as necessary.