标签: messagebox

消息框

德尔福 ; Application.MessageBox,Windows.MessageBox或Dialogs.MessageDlg之间有什么区别?或者使用计算机内存更有效率?

delphi messagebox

4
推荐指数
1
解决办法
5695
查看次数

替换是/否/取消MessageBox(C#)

我正在寻找标准窗口YES/NO或YES/NO/CANCEL MessageBox的合适替代品.

我经常看到这些标准对话框被滥用的方式如下:"以纯文本格式保存答案是,或保存在HTML答案中".显然,文本应显示为"另存为:"按钮应标记为"文本"和"HTML".这不是一个肯定/没有问题的问题,虽然它可以用这种方式表达,但阅读和理解并不容易.

Microsoft无法更改按钮上的文本.没有快速/简单的方法可以从头开始构建替换...正如使用上述笨拙风格的应用程序数量所证明的那样.

是否有任何免费的C#替换对话框或MessageBox,至少可以让你:
- 指定按钮的数量
- 指定每个按钮上显示的文本
- 指定

我看过的默认按钮,但无法找到.

(我会自己构建一个,但是我不熟悉完全功能控件应该具有的所有行为,因为我只需要/使用/知道一个小子集.我不使用的两个例子:主题和国际化.I需要我的同事也想要使用的东西.)

c# messagebox winforms

4
推荐指数
1
解决办法
7160
查看次数

我如何从App.xaml.cs运行MessageBox.Show()

我可以从App.xaml.cs运行MessageBox.Show(),因此它显示在当前页面上.请为此解决方案或其他解决方案提供一些代码.我需要显示一些与整个应用程序相关的系统消息.

c# messagebox windows-phone-7

4
推荐指数
1
解决办法
1万
查看次数

在QmessageBox中显示图像

如何在消息框中显示图像.我试过了

about.setIcon(":/pics/goku3.jpg");
Run Code Online (Sandbox Code Playgroud)

但它给了我错误.我知道我可以使用内置的盒子.这是显示此框的完整代码.

void MainWindow::on_actionUmer_s_Program_triggered()
{
    QMessageBox about;

    about.setText("Umer's Program");
    about.setInformativeText("Copyright ; 2012 Umer Software Inc.\nI wrote this program     for fun.\n);
    about.setStandardButtons(QMessageBox::Ok);
    about.setIcon(":/pics/goku3.jpg");   // here is the error
    about.setDefaultButton(QMessageBox::Ok);
    about.show();
    about.exec();
}
Run Code Online (Sandbox Code Playgroud)

还请告诉我如何设置该图像的大小.

c++ qt messagebox

4
推荐指数
1
解决办法
8975
查看次数

不等待messageBox的结果

当在当前用户测试的客户端应用程序中捕获未处理的异常时,我创建了这样的代码.

catch(Exception ex)
{
    var result = MessageBox.Show(ex.Message, "Error", MessageBoxButton.OK);
    Current.Shutdown();
}
Run Code Online (Sandbox Code Playgroud)

但是消息框只会很快出现,然后程序关闭.为什么代码不等待结果显而易见.我该怎么办?

.net c# wpf messagebox

4
推荐指数
2
解决办法
9110
查看次数

如何在类库c#中使用Messagebox?

如何在类库中使用MessageBox?

这是我的代码

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace MessageBoxes
{
    class ShowInfo
    {
        MessageBox.Show("test");
    }
}
Run Code Online (Sandbox Code Playgroud)

我可以加载MessageBox但不能有show属性,MessageBox.Show("test"); < - 失败

.net c# messagebox

4
推荐指数
1
解决办法
3万
查看次数

按钮单击java中的showMessage

我在JApplet中创建了一个按钮.如何使用它打开消息框?

okButton = new Button("Miow");
okButton.setBounds(20,20,1150,30);
add(okButton);

//like
if(okButton)
{
    JOptionPane.showMessage......
}
Run Code Online (Sandbox Code Playgroud)

java messagebox jbutton

4
推荐指数
1
解决办法
1万
查看次数

如何在Windows 8.1中获取MessageBox图标

我想获得MessageBoxIcons,当用户出现时会显示MessageBox.早些时候我为此目的使用了SystemIcons,但现在它似乎返回的图标不同于MessageBox.

这导致了在Windows 8.1中SystemIcons和MessageBoxIcons不同的结论.我知道使用WinApi MessageBox获取图标,但我似乎无法以任何方式获取图标.

我想问一种检索这些图标的方法.

c# icons messagebox windows-8.1

4
推荐指数
1
解决办法
2247
查看次数

C#WinForm中MessageBox的连续弹出

这是我的代码:

private void btnReminder_Click(object sender, EventArgs e)
{
    timer2.Start();
}

private void timer2_Tick(object sender, EventArgs e)
{
    DateTime Date = DateTimePickerReminderDate.Value;
    DateTime Time = DateTimePickerReminderTime.Value;
    if (DateTime.Now.CompareTo(Date) > 0 && DateTime.Now.CompareTo(Time) > 0) 
    {
        Date = DateTime.MaxValue;
        Time = DateTime.MaxValue; 
        MessageBox.Show("Your Reminder");

        timer2.Stop();     
    }
}   
Run Code Online (Sandbox Code Playgroud)

当我设置提醒它按预期工作并在正确的时间显示消息.但问题是,它不断弹出消息框我试图清除这个错误但我没有成功.所以我现在需要专家建议所以请帮我清除这个bug.

c# messagebox winforms

4
推荐指数
1
解决办法
280
查看次数

WPF消息框显示错误消息

我正在开发WPF应用程序,并且想要显示带有诸如信息或问题之类符号的消息框。我写了这段代码:

MessageBox.Show("Added Sucessfully","Alert",MessageBoxImage.Information);
Run Code Online (Sandbox Code Playgroud)

但显示错误/红线

错误:system.windows.messagebox.show(string,string,messageboximage)有一些无效的参数

c# wpf messagebox

4
推荐指数
1
解决办法
7228
查看次数

标签 统计

messagebox ×10

c# ×7

.net ×2

winforms ×2

wpf ×2

c++ ×1

delphi ×1

icons ×1

java ×1

jbutton ×1

qt ×1

windows-8.1 ×1

windows-phone-7 ×1