Consider a XAML TextBox in Win Phone 7.
The goal here is that when the user presses the Enter
Was faced with the same problem; the examples above only gives details about how to trap the keyboard press event (which answers the question), but to disable the keyboard, onclick or enter, I just have the focus set to another control altogether.
Which will result in disabling the keyboard.
private void txtCodeText_KeyDown(object sender, KeyEventArgs e)
{
if(e.Key.Equals(Key.Enter))
{
//setting the focus to different control
btnTransmit.Focus();
}
}