繁体   English   中英

Xamarin.Forms 绑定默认值到 DisplayPromptAsync

[英]Xamarin.Forms bind default value to DisplayPromptAsync

是否可以DisplayPromptAsync

await DisplayPromptAsync("", "DEFAULT VALUE IS:", "ОК", "CANCEL","PLACEHOLDER");

添加默认值?

例如,我想在用户打开 DisplayPrompt 时发送一封建议电子邮件。

是的,最新版本中有这个参数

public System.Threading.Tasks.Task<string> DisplayPromptAsync (
    string title, string message, string accept = "OK", 
    string cancel = "Cancel", string placeholder = default, 
    int maxLength = -1, Xamarin.Forms.Keyboard keyboard = default, 
    string initialValue = "");

使用initialValue

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM