Random Technical Stuff RSS 2.0
 Friday, September 04, 2009

With the release of Internet Explorer 8 (IE8), there is some new functionality that enables a developer to extend the browser pretty easily.  One of my particular favorites is the ability to create accelerators.  Accelerators allow a user to invoke a service from another site based on the text selected in the current page.  Some examples of accelerators that are available by default include:

  • Take what ever text is selected and search on Bing
  • Select an address and see the map inline with Bing Maps
  • Select text in a foreign language and translate it on the fly (below is an on the fly translation from the Al Jazeera site)

image

It is pretty easy to write your own accelerators for search.  In a recent presentation I showed how to write a fairly basic one for searching Stack Overflow.  It is just an XML file that describes to the browser how to handle the activity.  Here is the code for that particular accelerator:

<?xml version="1.0" encoding="utf-8" ?>
<openServiceDescription xmlns="
http://www.microsoft.com/schemas/openservicedescription/1.0">
  <homepageUrl>
http://www.stackoverflow.com/</homepageUrl>
  <display>
    <name>Search on Stack Overflow</name>
    <icon>
http://www.stackoverflow.com/favicon.ico</icon>
  </display>
  <activity category="Search">
    <activityAction context="selection" >
      <execute method="get" action="
http://stackoverflow.com/search?q={selection}" />
    </activityAction>
  </activity>
</openServiceDescription>

Let’s take a look at each of the pieces that need to be changed to create a new accelerator.  In this example I will write one that will take the selected text and search on weather.com.  I think about this as the example where I might have my online itinerary and can select a zip code or city name and be taken directly to where I can see the upcoming weather.

 

First thing we need to do is change the <homepageUrl> element.

<homepageUrl>http://www.weather.com/</homepageUrl>

Next we need to create the icon/text the use will see when they invoke the accelerator.  Note that most sites that use an icon that appears in the browser have their icon stored at the root web under the name favicon.ico, but that isn’t universal – double check to ensure that it is there.

  <display>
    <name>Check weather on Weather.com</name>
    <icon>
http://www.weather.com/favicon.ico</icon>
  </display>

 

Finally, we need to give an action for the browser.  In this case we will open up a new tab with the search performed.  To figure out the URL, I usually do a search on the site and grab the URL.  I usually search for the term “selection” which will give me the direct URL.  In the case of weather.com we get a URL of

 

http://www.weather.com/search/enhancedlocalsearch?whatprefs=&what=WeatherLocalUndeclared&lswe=selection&lswa=WeatherLocalUndeclared&from=searchbox_localwx&googleTypeSearch=on&where=selection

 

I played with the URL a little bit to get rid of any extraneous information and found that the following URL worked also

 

http://www.weather.com/search/enhancedlocalsearch?where=selection

So the activity section of the XML would be:

  <activity category="Search">
    <activityAction context="selection" >
      <execute method="get" action="http://www.weather.com/search/enhancedlocalsearch?where={selection} “
/>
    </activityAction>
  </activity>

Notice that I have taken the text “selection” and surrounded it with curly braces.  This tells IE to replace the text when opening up the URL.  So the final XML file for the accelerator would be:

<?xml version="1.0" encoding="utf-8" ?>
<openServiceDescription xmlns="
http://www.microsoft.com/schemas/openservicedescription/1.0">
  <homepageUrl>
http://www.weather.com/</homepageUrl>
  <display>
    <name>Check weather on Weather.com</name>
    <icon>
http://www.weather.com/favicon.ico</icon>
  </display>
  <activity category="Search">
    <activityAction context="selection" >
      <execute method="get" action="http://www.weather.com/search/enhancedlocalsearch?where={selection}”
/>
    </activityAction>
  </activity>
</openServiceDescription>

 

Next we need to write an html page that will trigger IE to install the accelerator.  This is done by firing a piece of JavaScript that only works on IE8.  Here is the simple HTML to fire that JavaScript when a button is pressed.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title>Weather.com Accelerator Install</title>
</head>
<body>
    <p>
         <button id="WeatherButton"
                     onclick="window.external.AddService('http://localhost/Accelerators/Weather/WeatherSearch.xml')">
                     Install Weather.com Accelerator
         </button>
     </p>
</body>
</html>

Note the “window.external.AddService” call.  The argument of that method needs to point to the location of the xml file we created above. 

 

If you would like to try out the install experience you can go to the install page on my site.  If you would like to download the files we have created above you can find them on my public SkyDrive folder.

4-Sep-2009 11:26 AM  #   


 Tuesday, August 11, 2009

ARCHITECT COUNCIL | Innovation is the Name of the Game

Architects:  Adverse times are also best times for innovation!  Choosing the right battles to fight, and reinventing ourselves with less resources are par for the course today.  However, not all innovation needs to be revolutionary or transformative. In fact, in the current economic crisis, opportunities for innovation can be found in aspects of our core competencies, and implemented as incremental and iterative changes.

For this series of Architect Council live webcasts on August 24 and 25, we will discuss two of the many ways architects can innovate by recognizing the impact to architects, and learning how to effectively leverage cloud computing beyond just another place to host existing assets.

 

DAY 1 – August 24, 2009 at Noon PST

Role of the Architect in Turbulent Times  --  Event ID:  1032423112

Miha Kralj – Architect, Microsoft

With faltering economies and the resulting shift of priorities - architects must be ready for change in their role. Innovative new technologies such as Cloud Based Computing, Software as a Service and Virtualization open up new and exciting opportunities for architects to show value in their organizations.   In this session we will discuss how the role of the architect has changed, introduce new architectural patterns, and show how to "do more with less".

Link to Register:  ARCHITECT COUNCIL | Innovation is the Name of the Game Day 1 Live Meeting

 

DAY 2 – August 25, 2009 at Noon PST

A Closer Look at an Internet Service Bus  --  Event ID:  1032423113

Clemens Vasters – Program Manager .NET Online Services, Microsoft

Look under the hood of the Microsoft .NET Services service bus - the protocols we use- and how to use the services from non-Microsoft platforms and languages.  Learn which part of the messages and requests the Building Block service inspects, which parts are not inspected, and how you can verify this.  Also, learn how to work through NAT and Firewall limitations.   Lastly, hear about architecture on the Data Center side that enables "Internet scale”.

Link to Register:  ARCHITECT COUNCIL | Innovation is the Name of the Game Day 2 Live Meeting

SPEAKER BIOS

Miha Kralj

As a senior architect on the Microsoft Platform Architecture Team, Miha Kralj is responsible for leading architectural communities, helping the architectural profession to mature and grow, and coordinating activities within professional architectural organizations and bodies. Miha is a Microsoft Certified Architect (MCA), Project Management Professional (PMP), and Certified Information Systems Security Professional (CISSP). He was also a founding member of the Project Management Institute (PMI) chapters in Slovenia and Yugoslavia.

 

Clemens Vasters

Clemens Vasters is a Principal Technical Lead in the .NET Services team, working in an architect role on the 'Service Bus' feature area and acting – more behind the scenes – as the architect for the Billing feature area and as the architect/lead developer for the internal Provisioning infrastructure of .NET Services. Before joining Microsoft some 3 years ago, Clemens spoke at many conferences, taught technology, and helped companies with software architecture in over 35 countries.

11-Aug-2009 3:22 PM  #   


 Wednesday, June 17, 2009

The Generations Network runs one of the most popular genealogy websites in the world – ancestry.com.  One of the things they wanted to provide their users was a simplified way to browse and edit their family tree.  Even smaller trees can become a bit unwieldy and very large trees can become nearly impossible to navigate – particularly when you talk about using html based technologies.  The team at TGN decided to leverage a Rich Internet Application platform and after surveying the existing technologies decided that Silverlight was the best technology to use in this situation. Microsoft has produced a case study documenting their project which you can find here.

From the case study:

The Generations Network (TGN), through its flagship Ancestry.com Web site, is the world’s leading resource for online family history, providing services to millions of users worldwide. To enhance the appeal of its Web sites, TGN wanted to revamp its Family Tree Viewer application to provide a graphically rich experience and fast performance—a combination that was hard to deliver with its existing development tools. The company decided to become an early adopter of the Microsoft® Silverlight™ browser plug-in, which is based on development tools that TGN is already familiar with such as Microsoft Visual Studio® Team System 2008 Team Suite and Microsoft Visual C#®. TGN used Silverlight to create a prototype of the application an estimated 30 percent faster than it would have taken using Adobe Flash. TGN expects the rich Internet application to keep the company ahead of its competitors.

17-Jun-2009 4:02 PM  #   


One of the customers that I have worked with for quite some time is Archstone.  They are a top notch organization that have done a lot of interesting things with technology do set themselves apart in the apartment management space.  Recently they just completed a rollout of a kiosk based solution for prospective residents that is really impressive.  It was interesting enough that Microsoft put together a case study to highlight the details of the project.  You can check it out here.

A little bit from the case study:

Luxury apartment owner and operator Archstone wanted to create a better, faster, and more consistent way for its leasing agents to work with—and close leases with—prospective residents. The need was most acute when Archstone was leasing units in buildings under construction, which made on-site tours difficult. The company found a solution: self-service kiosks in sales offices that run a highly visual and interactive solution built with Microsoft® technologies including Visual Studio® Team System 2008 and the Microsoft .NET Framework 3.5. The kiosks have improved the customer experience, reduced the time required to close, and contributed to an increase in occupancy upon opening for the company’s newest apartment development. Archstone developed the solution in half the time that it would have taken using other technologies, and the company anticipates extending the solution to the Web.

17-Jun-2009 3:39 PM  #   


 Friday, June 12, 2009

After I finished off my TechEd Interview with Scott Hanselman in May, I had to take him over for an interview for the MSDN Summer Bytes series.  This series is a fun an fairly humorous look at what technologies are getting people excited this summer.  It was conceived and executed by a couple of very sharp people in our marketing department (Erin Jacobs and Nora Kelly) and I really like what I have seen so far.  There are some fantastic people that were interviewed.  I recommend that you check it out and if you like it, subscribe to the RSS feed.

12-Jun-2009 10:26 AM  #   


A few members of my team just completed a series of online webcasts this week which went very well. The topics were on Patterns for Moving to the Cloud, Patterns for Silverlight and WPF with Prism, and Patterns for Parallel Computing.  The slides and session recordings are available for anyone.  Click here to see more information.

12-Jun-2009 9:58 AM  #   


 Thursday, June 11, 2009
A “First Look” at BizTalk Server 2009! – June 23, 2009

Enterprises across the world need to build applications that span their network and bring together services, systems, and people. The new BizTalk Server 2009 enables this connectivity while eliminating many of the cost and complexity challenges enterprises currently face.

Microsoft product specialists and experts from gold-certified partner Neudesic will give you a “first look” at BizTalk Sever 2009 and how they can help streamline and integrate business processes while reducing cost and complexity.

Microsoft Denver Office 8:30am – 11:30am

 

Click here to register

Invitation Key: B185E8

or call 877.673.8368 with

Event ID: 1032414999

11-Jun-2009 5:27 PM  #   


 Tuesday, May 26, 2009

Patterns!

EVENT OVERVIEW

“Cloud computing will supersede traditional IT”, “SOA will enable business agility”, “my way or the highway”, etc. We’ve all heard this type of proclamations before, as many look to the “next big things” in technology to exact sweeping changes and solve many issues; truth is, technologies and tools aren’t as instrumental in influencing progress, as the design and discipline in applying them to specific issues. When used appropriately, technologies and tools can be powerful enablers that bring about change.
One of the things we hear a lot working with the community is a desire for more guidance about how to use the technology instead of just talking about features and functions.  To address this, our team has put together a series of live webcasts on June 9th – 11th which will focus on guidance and patterns for some of today’s hottest topics.

SESSION DETAILS

DAY 1 - June 9, 2009 at Noon PST
Patterns for Moving to the Cloud
Larry Clarkin & Wade Wegner
Everything that you read these days seems to suggest that you should be moving to the cloud. But where do you start? Which applications and services should you be moving? How do you build the bridge between on-premises and the cloud? And more importantly, what should you be looking out for along the way? In this session, learn architectural patterns and factors for moving to the cloud. Based on real-world projects, the session explores building block services, patterns for exposing applications, and challenges involving identity, data federation, and management. This session provides the tools and knowledge to determine whether cloud computing is right for you, and where to start.

 

DAY 2 - June 10, 2009 at Noon PST
Building Silverlight & WPF Applications with Prism
David Hill
Prism provides guidance, via design patterns, to help you build robust, flexible and modular Silverlight and WPF applications. These patterns support unit testing, separation of concerns, loose coupling and the ability to share application logic between Silverlight and WPF applications. Prism includes source code for the library itself, extensive documentation, and a sample application that shows how the patterns work together in a real-world application. It also includes a Visual Studio add-in to help you easily share code between WPF and Silverlight. This session provides an overview of Prism, and shows how you can use Prism to design and build composite Silverlight applications.

DAY 3 - June 11, 2009 at Noon PST
Patterns for Parallel Computing
David Chou
With recent advances in cloud computing, service-oriented architectures, distributed computing, server virtualization, multi-core processors, etc., we are now seeing parallel computing techniques being implemented across the spectrum, and towards mainstream applications such as internet-scale web applications, massive data processing, graphics rendering, etc. But the myriad of choices also present a number of questions on when and how to utilize parallel computing. This session explores the architectural patterns and trade-offs between different forms of parallel computing, approaches for utilizing them to improve application performance and optimize use of existing infrastructure, and how concurrency can be applied towards day-to-day enterprise information processing needs.

WEBCAST AGENDA
  • 11:45 AM (PST) - Open for Dial-in
  • 12:00 PM (PST) - Day's Content
  • 12:50 PM (PST) - Q&A
  • 01:00 PM (PST) - Raffle and Close
REGISTRATION

To register, please click on the link below for each day:

We will email you with the Live Meeting information and log-in details a few days before the actual event.  We will use the email address you provide in the registration. Thanks!

26-May-2009 2:46 PM  #   


 Tuesday, April 28, 2009

I usually don’t like to promote every little thing that Microsoft releases, but when I see something that is really worth downloading, I like to point it out.  Office 2007 Service Pack 2 is out and downloadable here.  If you are running Office 2007 I highly recommend installing this particular Service Pack.  The performance and reliability fixes for Outlook are very good.  I have been running a beta of this Service Pack for a bit and it fixed the “Your Outlook data file was not closed properly” issue.  I have also noticed that Outlook has been much more responsive and reliable.  Well worth the 260 MB download.

28-Apr-2009 1:37 PM  #   


  
Archive
<September 2009>
SunMonTueWedThuFriSat
303112345
6789101112
13141516171819
20212223242526
27282930123
45678910
About the Author/Disclaimer

Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.

© Copyright 2010
Joe Shirey
All Content © 2010, Joe Shirey