A great tool if you have more than one computer on your desk

A few years ago, I found a tool to share the keyboard and mouse of one computer with another computer. That looks like this:

image
(Source: http://synergy-foss.org/)

As you can see, the tool also runs on any platform not only Windows.

Today I have two laptops on my desk and thought about that great tool. Now I found it again. It is called “Synergy” and can be downloaded for free here. The author updated it and it works very well.

Configuration

The configuration is farely easy:
On the computer with the keyboard and mouse, start the tool, click “Configure Server” and you will get this dialog:

image

There you can drag computers around your existing one where they physical are placed.
Now save and click start.

On the other computers select “Client” and enter the hostname or IP address of the host computer. Done.

My first Windows Phone 7 application: MySite for WP7 - Part 1

A few weeks ago, my employer, Avanade Germany, announced an internal “Windows Phone 7 Contest”. The goal is to create a (business) app for Microsofts new Windows Phone 7 (WP7) system. I just had some ideas and decided to go with “MySite for WP7”. At least because I’m working in the “Portals & Collaboration” Service Line and I really like the new SharePoint 2010 MySite. That, and because the price for the best three apps is an Xbox 360 with Kinect. Winking smile

Overview

If you have no idea, what the SharePoint 2010 MySite is, here is a short introduction: Think about a “little” Facebook (social network) within your company. You can write status messages, see a newsfeed about your colleagues, post comments on the note boards of your colleagues, upload pictures, etc.

I know, that WP7 comes with SharePoint integration, but without a cool client for the MySite. I will try to build one (and hopefully win the Xbox).

Start with WP7

I will not give you an overview what you need to start, because there are a lot of resources to learn WP7 development. I already know .NET, C#, SharePoint and Silverlight and that’s everything you need to start. Download the Development Toolkit (for free) and start up Visual Studio.

First of all I decided to go with the Panorama Template, because it is easy to use and looks really nice. Also it supports my idea of different MySite tasks. The design-time support is great as well. If you click on the panorama page in the XAML code, the designer shows the corresponding page.

image

But before I go into much UI details, we should thought about the backend.

How to connect to SharePoint?

SharepPoint 2010 provides a web services API (WCF and legacy ASMX) to access most of the SharePoint functionality. Therefore I tried to access these services directly from the phone, but that did not work, because of two main points:

So obviously a workaround is required. Here is my idea of a “proxy service”:

image

That means, the WP7 app connects to an SSL secured WCF (silverlight-enabled) proxy service (without authentication) in the cloud. The service then connects to the SharePoint service with the provided credentials. For privacy reasons, a company that do not want to transmit sensitive data over the cloud service can host their own proxy service within their secure environment to make it accessible by their employees.

The proxy service can for example get the current status message from your MySite:

public string GetStatus(AccountCredentials credentials)
{
  var client = GetProfileServiceClient(credentials);

  string fqnUsername = credentials.Domain + "\\" + credentials.Username;
  var data = client.GetUserProfileByName(fqnUsername);

  var statusProp = (from d in data
                    where d.Name == "SPS-StatusNotes"
                    select d).FirstOrDefault();

  return statusProp.Values[0].Value.ToString();
}

I defined a class AccountCredentials which contains username, domain, password and SharePoint MySite URL. This data is entered in the WP7 app by the user. Now the proxy service is called with this data and calls the SharePoint profile service (with the URL provided) to get the current status message.

This approach is not only for communicating with SharePoint, but can also be used with other services which cannot directly be called from the phone.

Alternative to a Proxy Service: UAG

Another fairly new (at least for me) way is the Forefront Unified Access Gateway (UAG). See also this video from TechED. In the video you can see, that Microsoft requires a company to have a UAG in place to use the build-in SharePoint features of WP7. So it seems, that also Microsoft cannot use NTLM on WP7.

WP7 with UAG uses HTTPS for all communications and what is know as basic authentication. One problem why I’m currently not supporting UAG in my App is, because there are no developer resources how to integrate it in your own application. The only info you got from the video is to use signUrl.asp to get the token after authentication. If anyone has more info, please add a comment.

Learn more in part 2 of the series in a few days where I will talk about the User Interface.

Proxy Switcher meets Facebook, Twitter and SharePoint 2010 MySite

I was on vacation the last two weeks so I had some time for some funny things. For Proxy Switcher I thought it would be a nice idea to have an AddIn to set the status message of social networks on a network change. The two major players are Facebook and Twitter. Personally I’m not using Twitter, but that’s another story. Additionally, at Avanade we have our MySites on SharePoint 2010 with the new feature enabled to add status messages there as well. (See also our Avanade SharePoint Blog)

image

Your TODO now: Download Proxy Switcher (if its not already installed), then go to the More AddIns page to download the “Social Media Update Action AddIn”.

Proxy Switcher – Version 3.1

Es ist soweit und Proxy Switcher steht in einer komplett überarbeiteten Version bereit. Inzwischen ist auch die Version 3.0 übersprungen und die neue Version enthält eine Menge neuer Funktionen. Mehr dazu auf der Projekt Seite und im Changelog.

Nur die Group Policy Funktionen sind leider immer noch nur eingeschränkt verfügbar, stehen aber für die nächste Version ganz oben auf der Liste.

Wünsche und Fehler können wie gehabt im Forum angesprochen werden oder direkt im Bug Tracker eingetragen werden.

Proxy Switcher 3 – BETA

Ab sofort gibt es den Proxy Switcher v3 als öffentliche Beta zum download.

DOWNLOAD HIER

Wichtig: .NET Framework 4 wird benötigt.
Desweiteren liefen die Tests bisher nur auf Windows 7.

Alle auftretenden Probleme und Vorschläge bitte hier eintragen:

http://bugs.mwiedemeyer.de

 

Ein paar Highlights:

Komplettes Re-Design (Sichtbar und im Hintergrund)
MEF als AddIn Framework
Ribbon User Interface (http://fluent.codeplex.com/)
Windows 7 Location API Integration

Windows 7 Location API – A new feature for Proxy Switcher

Overview

Currently, I’m investigating what can be improved in the new release of Proxy Switcher.

For those of you, who don’t know what Proxy Switcher is a few facts:

  • Proxy Switcher automatically set the proxy depending on your current network connection
  • Beside of that, it can set other things too. E.g.: Execute scripts, change default printer, etc.
  • Click here to go to the project site for more info

Windows 7 Sensor and Location Platform

With Windows 7 Microsoft created a new “Sensor and Location Platform”. Until now, there is not much hardware compatible with it, but this hopefully will change in the near future.
With this API, applications can easily access the available sensors. Here you can find some examples and also a “manual” location provider by clicking on a map.

For the location API, there is a cool free “software” device called Geosense. From their website:

Geosense is designed to use a hybrid mix of geolocation service providers and geolocation methods to pinpoint the most accurate location information possible - including but not limited to WiFi triangulation, cell tower triangulation and IP lookup. Source: http://www.geosenseforwindows.com/

While your laptop vendor has not yet integrated a Windows 7 compatible hardware GPS sensor, Geosense is a good compromise.

Proxy Switcher Integration

For Proxy Switcher this will become a new option for switching proxy configurations, or doing some other stuff as you can see here:

image  (click to open in a new window)

 

Code

To access the Windows 7 location API all you need is the .NET Framework 4. There is a new System.Device.dll (contained in the Client Profile of the .NET Framework). Adding a reference allows you to access the current location.

First, add the following using statement:

using System.Device.Location;

Use the following code  to get the address:

GeoCoordinateWatcher watcher = new GeoCoordinateWatcher();
watcher.TryStart(false, TimeSpan.FromMilliseconds(1000));
// Get the location, including lat, long, speed, altitude, etc.
GeoCoordinate location = watcher.Position.Location;
// Try to get the current address, including street, city, etc.
CivicAddressResolver resolver = new CivicAddressResolver();
CivicAddress address = resolver.ResolveAddress(location);

Summary

With this new functionality, Proxy Switcher is not a pure “Proxy Switcher” anymore, but a multi-functional network/location based “generic” extensible execution tool. New actions can be easily created by developers through the MEF AddIn Framework. More on this in a later post.

 

If you want to become a beta tester, feel free to contact me at “mail” at thisdomain.

Windows Phone 7 Series

Das sieht doch mal sehr vielversprechend aus:

image

Mit einer Oberfläche, die der des Zune ähnelt und mir auch dort schon sehr gut gefallen hat.
Developer Infos gibts erst zu MIX, vielleicht gibts bis dahin dann auch das SDK.

Ich jedenfalls will so ein Windows Phone! Gibts dann hoffentlich zu Weihnachten nicht nur in den USA, sondern auch hier.

Proxy Switcher 2.0

English version below

Es ist endlich soweit und Version 2 ist fertig geworden.

Von der Roadmap musste die UI Überarbeitung allerdings vorläufig gestrichen werden. Das heißt es gibt keine Ribbons und kein WPF, sondern weiterhin das Tabbed Interface wie gehabt. Allerdings ist zum deaktivieren ein neues Tab hinzugekommen.

Dafür aber nun die gute Nachricht: Neben einigen Bugfixes haben es die folgenden Features in die neue Version geschafft:

  • Standard Drucker wechseln nun auch beim deaktivieren
  • Neue Settings um das Taskbar Verhalten zu ändern und Nachfragen abzuschalten
  • Im Auto Switch Tab werden nun einige Werte (WLAN SSID, DNS suffix, Gateway) mit Werten des aktuell verbundenen Netzes vorbelegt
  • Wenn ein neues WLAN connected wird, erscheint eine Abfrage ob dieses WLAN einen Proxy benötigt, der dann direkt konfiguriert werden kann
  • Mehr Hilfen im Programm verfügbar durch überfahren von Fragezeichen mit der Maus
  • Application Änderungen:
    • Opera Support nun inkl. Opera 10
    • Firefox: Neben den Profilen kann nun auch der Standard Profilordner gewechselt werden
    • Thunderbird gehört nun ebenfalls zu den Unterstützten Applikationen
    • Internet Explorer 8: Proxy kann nun auch für Wählverbindungen gewechselt werden, allerdings aktuell nur mit einem kleinen Trick. Mehr dazu in der FAQ und im Tool über die Hilfe.
  • Neue Enterprise Features:
    • Alle Konfigurationsdateien ([User]\AppData\Roaming\ProxySwitcher) werden nun live überwacht und können per Group Policy, o.ä. geändert und ausgetauscht werden, ohne die Anwendung beenden zu müssen. Dies ermöglicht z.B. Proxy Einstellungen für alle Mitarbeiter hinzuzufügen oder zu ändern.
    • Group Policx (ADMX) Template: Proxy Switcher lässt sich nun über Group Policies einschränken und deaktivieren. Download und Infos hier: http://projects.mwiedemeyer.de/ProxySwitcher/pages/GroupPolicy.aspx
      Das Template ist nur für Windows Vista oder höher und Window Server 2008 oder höher anwendbar, da Microsoft erst ab dieser Version das neue ADMX Format eingeführt hat.

Download wie immer direkt hier: http://mwiedemeyer.de/downloads/ps/ProxySwitcherSetup.zip

Für Fragen und Anregungen bitte die FAQ und das Forum hier verwenden: http://projects.mwiedemeyer.de/ProxySwitcher

 

----------------------------------------------------------------------

ENGLISH VERSION

Today the new version 2 was released!

The UI changes mentioned in the roadmap had been postponed. So no ribbons and no WPF, but a tabbed interface like in the releases before with an additional tab for deactivating the proxy.

The great news: Beside some bug fixes there are many new features available as you can see here:

  • Change the default printer also on deactivating the proxy
  • New settings to change the taskbar behavior and eliminate ask on exit
  • Within Auto Switch tab, switch settings will be pre-populated with the values (WLAN SSID, DNS suffix, Gateway) from the currently connected network
  • When you connect to a new WLAN, a task dialog appears and you can directly create a proxy entry for this connection
  • More help available throughout the application (hover the mouse over the question marks)
  • Application changes:
    • Opera support including Opera 10
    • Firefox: Also change the default profile folder
    • Thunderbird support added
    • Internet Explorer 8: From now on, proxy can be changed for dial-up connections too. See FAQ or help within the tool for a how-to.
  • New Enterprise features:
    • All configuration files ([User]\AppData\Roaming\ProxySwitcher) are now live monitored, so they can be changed or replaced by policies, etc. without exiting the application. Now it is possible to add or remove proxy entries for all employees.
    • Group Policy (ADMX) template: Proxy Switcher can now be managed by group policies. Download and info here: http://projects.mwiedemeyer.de/ProxySwitcher/pages/GroupPolicy-en.aspx
      The template is only available on Windows Vista or above or Windows Server 2008 or above, because Microsoft supports the new ADMX file format only in these versions.

Direct download here: http://mwiedemeyer.de/downloads/ps/ProxySwitcherSetup.zip

Please use the FAQ or the forum for questions and feedback here: http://projects.mwiedemeyer.de/ProxySwitcher