TechEd Gadget: development lessons learned

March 26th, 2009 by Adi S.
 
In my previous post on TechEd 2008 Countdown implementation I promised to share development lessons/tips learned and this post serves that exact purpose.
 
Gadget development turned out to be most development fun I have had in a while. Even though it is fairly straightforward there are several exceptions to the standard Web page development that I would like to share in order to save you research time in the future:
  1. Make sure to use both pairs of tags when specifying the location of your script file. A self-terminating tag such as <script…/> will not cut it and your gadget will not function as expected.
  2. OnMouseOver event seems to be disabled as far as opening of the flyout window goes. The onClick event will have to do. If somebody has a solution for this one please let me know as I hate to disappoint my friends who requested this feature.
  3. I was not able to set the background color of the gadget pages via bgColor property or the background-color style in a CSS file. However, the color specified in the style embedded in the BODY tag worked fine.
  4. Opening flyout window with another one already open creates this weird “loss of focus” effect. In order to avoid this check if the flyout window is already open and if so simply refresh the information contained within it. Code below demonstrates this much better than my narrative.
if(System.Gadget.Flyout.show)
     //flyout already open - call its function that loads the data
     System.Gadget.Flyout.document.parentWindow.loadPost();
else
     //display the flyout
     System.Gadget.Flyout.show = true;
 

The time spent researching these items is nothing compared to the joy of seeing the final result in action (as shown below) and reading all of the great posts by the TechEd community members. The final product can be downloaded here or by clicking any one of the images below. Enjoy!

  TEDev   TEGen   TEITPro

 

Tags: , ,

Leave a Reply