Asp.Net教程,WinForm教程,Asp.Net MVC,vs2008教程,vs2010教程,Silverlight技术,源码下载,Asp.Net视频教程
全站热门标签
vs2010 Silverlight 存储过程 水晶报表 ADO.NET JavaScript LINQ AjaxPro DataGridView 面向对象 Extjs GridView XML DevExpress HTML教程 Oracle jQuery 分页 GDI+ Visual C++2010 MySQL Office2010 WPF MVC Dojo WCF4.0 VB.NET Sql2005 textbox cookie WCF WinForm Discuz!NT SQL经典语句 T-SQL checkbox ASPxGridView F# asp.net SQL VS2008新特性 DropDownList Access TreeView Ajax VS2008 页面执行时间 Flex 字符串 回调 VB2005 DataSet C#时间 ASP.NET性能优化 用户在线检测 动画
Framework C#技术 VB.NETVC.NET WCF WPF
当前位置: 主页 > WinForm教程 > VC.NET >

一个CTaskDialog类使用的例子(MFC VC 2010)

时间:2010-04-25 10:02来源:未知 作者:admin 点击:

 

 

CString message("This is an important message to the user.");

 

CString mainInstruction("Important!\nPlease read!");

CString title("Alert Dialog");

 

CTaskDialog taskDialog(message, mainInstruction, title,

    TDCBF_YES_BUTTON | TDCBF_NO_BUTTON | TDCBF_CANCEL_BUTTON );

 

// Setting new information to be able to reuse the dialog resource

taskDialog.SetWindowTitle(L"New title for the task dialog");

taskDialog.SetContent(L"New message to show the user.");

taskDialog.SetMainInstruction(L"Even more important!");

taskDialog.SetMainIcon(TD_ERROR_ICON);

taskDialog.SetDialogWidth(300);

 

// Add a footer

taskDialog.SetFooterText(L"Footer information for the dialog.");

taskDialog.SetFooterIcon(TD_INFORMATION_ICON);

 

// Add expansion information

taskDialog.SetExpansionArea(L"Additional information\non two lines.",

    L"Click here for more information.",

    L"Click here to hide the extra information.");

 

// Change the options to show the expanded information by default.

// It is necessary to retrieve the current options first.

int options = taskDialog.GetOptions();

options |= TDF_EXPANDED_BY_DEFAULT;

taskDialog.SetOptions(options);

 

taskDialog.DoModal();

(责任编辑:admin)
Tags:MFC C++2010
责任编辑:admin
返回顶部
------分隔线----------------------------
推荐内容
骆驼户外男 真皮磨砂日常休闲鞋 低帮 2011秋冬新款 专柜正品特价 骆驼户外男 真皮磨砂日常休闲鞋 低帮 2011秋冬新款 专柜正品特价