Home > Articles

This chapter is from the book

Using the Label Control

The Label control allows you to display text to the user. This is a simple control that does not warrant much explanation. The Text property of the control determines what text will be visible to the user. The display text can have a different alignment based on the TextAlign property. The possible align values are TopLeft, TopCenter, and TopRight. The TextChanged event is fired when the text in a Label control changes.

Handling the Pocket PC Hardware Buttons

The Pocket PC has a directional pad that can be used to interact with Pocket PC applications. It is possible to capture the events that this pad generates. When the pad is pressed, a KeyDown event is generated by the Form object. The event handler receives a KeyEventArgs object. The KeyEventArgs object exposes the KeyCode property. You can check the value of the KeyCode property to determine which direction on the pad was pressed. Table 3.4 lists the Key enumeration members that can be assigned to the KeyCode property and their associated buttons.

  • + Share This
  • 🔖 Save To Your Account