RSS

Tag Archives: Silverlight

Hover Intent for Silverlight

Updated: Now on GitHub: https://github.com/cairey/Hover-Intent-Silverlight

You have probably already used the Hover intent plugin for JQuery. Maybe you want to do the same thing for Silverlight? Well using the reactive extensions you can quite easily. Of course we are using MVVM so we can capture the elements mouse enter event and bind a command to it on the view model.

You can then bind in the XAML like so:
Button x:Name="Eyecon" commands:MouseEnterIntent.Command="{Binding Open}" commands:MouseEnterIntent.DueTime="50"

The MouseEnterIntent class creates the attached behavior using dependency properties. The MouseEnterIntentCommandBehavior class bind the events to the command.

Advertisements
 
Leave a comment

Posted by on September 21, 2010 in C# Development, Silverlight, Websites

 

Tags: , , , , , , , ,

Web Services in IE6 with Silverlight 2

I had an issue with calling web services from a Silverlight 2 application within Internet Explorer 6. I was a bit confused to why this was happening. After a quick browse on the web, I found this was quite a known problem. Unfortunately, still a lot of people use Internet Explorer 6, so it had to be supported! There are a few ways to fix the issue, but I found this way to work pretty well.

Switch off dynamic compression within IIS. Fortunately, there is a way to enable/disable dynamic compression for certain directories and pages. You can add the below to the <system.webServer> section in the web.config.

<urlCompression doStaticCompression=”true” doDynamicCompression=”true” />

This will enable compression for the entire application. To switch it off just for the web service you can add a location section like so…

  <location path=”FAService.asmx”>
    <system.webServer>
      <urlCompression doStaticCompression=”true” doDynamicCompression=”false” />
    </system.webServer>
  </location>

  <location path=”MyService.asmx”>

    <system.webServer>

      <urlCompression doStaticCompression=”true” doDynamicCompression=”false” />

    </system.webServer>

  </location>

 
Leave a comment

Posted by on May 11, 2009 in Silverlight

 

Tags: , , , , ,