Moving existing Phidgets.NET Applications To Shared Phidgets
<< Back to the SharedPhidgets page
The API of the components in new SharedPhidgets toolkit is nearly the same as in the Phidgets.NET toolkit. While there have been extensions to the API and there exist additional components, you can still access all object in nearly the same way as before. This tutorial describes, how you can port exisiting Phidgets.NET applications to the new SharedPhidgets toolkit.
The steps in general
- Load your Phidgets.NET project in VisualStudio.
- Remove the grouplab.phidgets reference
- Add the SharedPhidgets connection manager object and change the IP address
- Replace existing GroupLab.Phidgets.UI and GroupLab.Phidgets entries into GroupLab.SharedPhidgets
- Update references to components for the skins
- Finished! Recompile your application and have fun!
The procedure with an example: Simple servo
1) We load a simple servo control application that was created with the Phidgets.NET toolkit: it contains a servo object and a skin for this object.

2) At first we remove the grouplab.phidgets reference: right click on the reference and click remove.

3) Next, we add the SharedPhidgets connection manager object and change the IP address (insert here the address of your server).


4) Now, we have to replace all existing passages in the code that contains GroupLab.Phidgets.UI and GroupLab.Phidgets into GroupLab.SharedPhidgets. Use the Replace method of Visual Studio:

Replace AT FIRST the passages with GroupLab.Phidgets.UI to GroupLab.SharedPhidgets:

and then the passages with GroupLab.Phidgets to GroupLab.SharedPhidgets:

5) At last, update the property references to components for every of the the skins. Here in this example, we have only to change the servo property:

6) Finished! Recompile your application and have fun!