我想要Windows平板电脑的数字键盘。我用了密码
Keyboard="Numeric"但它为安卓设备、iOS设备和Windows提供数字键盘。它没有为Windows带来数字键盘。我参考了this link,它说在平板电脑中安装数字键盘是不可能的。我想知道有什么方法我可以得到这个功能。可能使用自定义呈现程序或依赖项注入。如果是的话,怎么做?
发布于 2019-02-27 09:45:40
这是已知的问题,它已经修复了最新版本,请将Xamarin.Forms nuget包版本更新为最新的稳定版本(包含在UWP客户端项目中)。

更新
[assembly: ExportRenderer(typeof(Entry), typeof(MyEntryRenderer))]
namespace App10.UWP
{
public class MyEntryRenderer : EntryRenderer
{
protected override void OnElementChanged(ElementChangedEventArgs<Entry> e)
{
base.OnElementChanged(e);
if (Control != null)
{
Control.InputScope = Element.Keyboard.ToInputScope();
}
}
}
}https://stackoverflow.com/questions/54886712
复制相似问题