我对C#不是很熟悉,现在要改一个C#写成的软件,从中文改成英文的,我想问问,有没有方法使得MessageBox上面的按钮变成英文版的?我知道在VC++中可以使用MessageBoxEx或者直接找到这个弹出框,再修改他上面的按钮。那么在C#中怎么实现呢?在英文操作系统中直接实现,我想知道能不能在中文系统中也有这个效果。我不是很熟悉C#,希望大家回答的时候能尽量详细点,谢谢了
调试欢乐多
中文系统 就是 否
英文系统就是 Yes No 其他的也一样
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;namespace WinInformation
{
public partial class SelectApp : Form
{
private string p_AppName = string.Empty;
private int int_year;
public SelectApp()
{
InitializeComponent();
}
private void SelectApp_Load(object sender, EventArgs e)
{
button1.DialogResult = DialogResult.OK;
button1.Text="Ok";
button2.DialogResult = DialogResult.Cancel;
button2.Text="Cancel";
}
}
}Fmain.cs SelectApp selectApp = new SelectApp();
if (selectApp.ShowDialog() == DialogResult.OK)
{
//DataShow DS = new DataShow(selectApp.AppName, selectApp.Int_Year);
//DS.ShowDialog();
//DS.Dispose();
}
selectApp.Dispose();
http://www.mybuffet.cn
当需要提示的时候就显示alertfrm form2=new alertfrm;form2.Show();这个窗体咯~~~~
你可以把这个窗体设置为焦点,这样你只有关闭了这个窗体才能继续操作
System.Threading.Thread.CurrentThread.CurrentUICulture = new System.Globalization.CultureInfo("en-US");
//SYS
System.Threading.Thread.CurrentThread.CurrentCulture = System.Globalization.CultureInfo.CreateSpecificCulture("en-US");