本文整理汇总了C#中MessageBox.SetTitle方法的典型用法代码示例。如果您正苦于以下问题:C# MessageBox.SetTitle方法的具体用法?C# MessageBox.SetTitle怎么用?C# MessageBox.SetTitle使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类MessageBox
的用法示例。
在下文中一共展示了MessageBox.SetTitle方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: wuc_ShowMessage
/// <summary>
///
/// </summary>
/// <param name="pInfo">Mensagem</param>
/// <param name="type">Tipo de Mensagem. 1 - information; 2 - warning; 3 - erro;</param>
public void wuc_ShowMessage(string pInfo, int type)
{
string appPath = HttpContext.Current.Request.ApplicationPath;
string physicalPath = HttpContext.Current.Request.MapPath(appPath);
MessageBox msgbox = new MessageBox(physicalPath + "\\Resources\\Config\\msgbox.txt");
msgbox.SetMessage(pInfo);
switch (type)
{
case 1:
msgbox.SetTitle("Informação");
if (appPath.ToString() != "/")
msgbox.SetIcon(appPath + "/Resources/Img/information.png");
else
msgbox.SetIcon("/Resources/Img/information.png");
break;
case 2:
msgbox.SetTitle("Atenção");
if (appPath.ToString() != "/")
msgbox.SetIcon(appPath + "/Resources/Img/warning.png");
else
msgbox.SetIcon("/Resources/Img/warning.png");
break;
case 3:
msgbox.SetTitle("Error");
if (appPath.ToString() != "/")
msgbox.SetIcon(appPath + "/Resources/Img/error.png");
else
msgbox.SetIcon("/Resources/Img/error.png");
break;
}
msgboxpanel.Visible = true;
msgbox.SetOKButton("msg_button_class");
msgboxpanel.InnerHtml = msgbox.ReturnObject();
}