开发者

Numeric Keyboard?

I have several instances in my application that I would prefer to use a numerical keyboard. Does one exist in WP7 and if s开发者_开发问答o, how would I go about popping that one up for a text box instead of the normal one?


You should use InputScope for the textBox

<TextBox Name="myTextBox" InputScope="Digits"/>

Here is the full list of InputScopes that are expected to be supported, based on the current enum names for InputScopeNameValue:

[NOTE] Even if you don't get the keyboard you want, you can still use it because it is highly possible to be supported in the future (final Mango probably)

http://www.imaginativeuniversal.com/blog/post/2010/07/06/WP7-InputScope.aspx

  1. AddressCity
  2. AddressCountryName
  3. AddressCountryShortName
  4. AddressStateOrProvince
  5. AddressStreet
  6. AlphanumericFullWidth
  7. AlphanumericHalfWidth
  8. ApplicationEnd
  9. Bopomofo
  10. Chat
  11. CurrencyAmount
  12. CurrencyAmountAndSymbol
  13. CurrencyChinese
  14. Date
  15. DateDay
  16. DateDayName
  17. DateMonth
  18. DateMonthName
  19. DateYear
  20. Default
  21. Digits
  22. EmailNameOrAddress
  23. EmailSmtpAddress
  24. EmailUserName
  25. EnumString
  26. FileName
  27. FullFilePath
  28. Hanja
  29. Hiragana
  30. KatakanaFullWidth
  31. KatakanaHalfWidth
  32. LogOnName
  33. Maps
  34. NameOrPhoneNumber
  35. Number
  36. NumberFullWidth
  37. OneChar
  38. Password
  39. PersonalFullName
  40. PersonalGivenName
  41. PersonalMiddleName
  42. PersonalNamePrefix
  43. PersonalNameSuffix
  44. PersonalSurname
  45. PhraseList
  46. PostalAddress
  47. PostalCode
  48. Private
  49. RegularExpression
  50. Search
  51. Srgs
  52. TelephoneAreaCode
  53. TelephoneCountryCode
  54. TelephoneLocalNumber
  55. TelephoneNumber
  56. Text
  57. Time
  58. TimeHour
  59. TimeMinorSec
  60. Url
  61. Xml
  62. Yomi
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜