Share via


Updating an RDP Setting from CETSC UI

Other versions of this page are also available for the following:

Windows Mobile Not SupportedWindows Embedded CE Supported

8/28/2008

Applies to Windows Embedded CE 6.0 R2 Update KB945975

This topic describes how to update a Remote Desktop Protocol (RDP) setting from Windows Embedded CE Terminal Services Client (CETSC) user interface (UI).

When you add UI elements to an existing property page or to a custom property page as a part of your UI customizations, you access and update RDP settings by using the Windows Embedded CE Terminal Services Client (CETSC) user interface (UI).

For example, to add a UI element that enables a user to decide whether to enable monitor spanning, you attach functionality to the UI element that reads and updates the RDP setting that controls monitor spanning.

Cetsc.exe has a settings store in which it stores values for RDP settings. When Cetsc.exe calls Initialize to establish communications between itself and cetscoem.dll, it passes two callback functions to cetscoem.dll. Then, cetscoem.dll uses these callback functions to read and write settings that are stored in CETSC UI. Cetsc.exe passes these callback functions into the first two parameters of Initialize.

To update an RDP setting in CETSC

  1. Start Platform Builder.

  2. Open cetscoem.cpp, located in %_WINCEROOT%\PUBLIC\RDP\OAK\CETSC.

  3. In the Initialize implementation, use the TscSettingsRead and TscSettingsWrite callback functions to retrieve and update specific RDP settings. These callback functions are the parameters lpSettingsRead and lpSettingsWrite. In your custom implementation, you can decide how to implement calls to these functions.

  4. On the Build menu, choose Global Build Settings, and then make sure that both Copy Files to Release Directory After Build and Make Run-Time Image After Build are selected.

  5. On the Build menu, choose Advanced Build Commands, and then choose Build and Sysgen.

After you complete these steps and re-build the run-time image, when cetsc.exe starts during run time, it will call the functions in cetscoem.dll and apply your customizations to the CETSC UI.

Example

The following lines of code show one way to call TscSettingsWrite:

_WriteSettings = lpSettingsWrite;
BOOL b = TRUE;
(*_WriteSettings)(OEMS_SPAN_MONITORS, (LPVOID)b);

If you prefer to call these functions by using a wrapper class instead of calling the callback functions directly, you can use the class CTscSettings. CTscSettings is defined in tscsetting.h, located in %_WINCEROOT%\PUBLIC\RDP\OAK\CETSC. If you use the functions in CTscSettings, you do not call lpSettingsRead and lpSettingsWrite directly. This class implements Get and Set functions that internally call the callback functions in order to access and modify RDP settings.

See Also

Other Resources

Customizing CETSC UI