Toast
--------------------------------------------------------------
var t = Windows.UI.Notifications.ToastTemplateType.ToastText02;
//在模板添加xml要的标题
var content = Windows.UI.Notifications.ToastNotificationManager.GetTemplateContent(t);
//需要using Windows.Data.Xml.Dom;
XmlNodeList xml = content.GetElementsByTagName("text");
xml[0].AppendChild(content.CreateTextNode("通知"));
xml[1].AppendChild(content.CreateTextNode("小文本"));
//需要using Windows.UI.Notifications;
Windows.UI.Notifications.ToastNotification toast = new ToastNotification(content);
ToastNotificationManager.CreateToastNotifier().Show(toast);
uwp 之吐司 toast
原创
©著作权归作者所有:来自51CTO博客作者bruce1992的原创作品,请联系作者获取转载授权,否则将追究法律责任
上一篇:C# 异步编程
下一篇:uwp 之资源的访问

提问和评论都可以,用心的回复会被更多人看到
评论
发布评论
相关文章
-
自定义吐司以及Toast的各种用法,详解。教你学会使用各种各样的Toast
package com.david_Custoast;import com.david
android开发 JAVA android androidstudio bundle -
android之【Toast】
public class ToastTest extends Activity{ @Override pub
android Toast 提示信息 ide 监听器 -
Android开发之Toast吐司的一个封装好的工具类。带有源代码java文件,
import android.content.Context;import android.widget.Toast; //Toast统一管理
JAVA android android开发 androidstudio 时间显示 -
uwp 之语音识别
xml code <Page x:Class="
xml Text microsoft -
Android--通知之Toast
前言 这篇博客讲解一下Android下的一个简单信息提示的方式:Toast。如果一直看我的博客,会发现在之前的Demo中,一直有用到Toast去提示消息,在这篇 例。.
android xml 自定义 ide 自定义布局