首先新建一个项目languageInfo:接着新建一个AppConfig.xml文件
<?xml version="1.0" encoding="utf-8" ?>
<AppConfig>
<Area>
<Language>ZH</Language>
<List>
<Item>中文[ZH]</Item>
<Item>英文[EN]</Item>
<Item>繁体[TH]</Item>
</List>
</Area>
<Area>
<Language>EN</Language>
<List>
<Item>Chinese[ZH]</Item>
<Item>English[EN]</Item>
<Item>Traditional[TH]</Item>
</List>
</Area>
<Area>
<Language>TH</Language>
<List>
<Item>中文[ZH]</Item>
<Item>英文[EN]</Item>
<Item>繁體[TH]</Item>
</List>
</Area>
</AppConfig>
接着再建一个
AppResource_EN.xml
<?xml version="1.0" encoding="utf-8" ?>
<Resource>
<Form>
<Name>frmlogon</Name>
<Controls>
<Control name="frmlogon" text="User logon"></Control>
<Control name="lblusername" text="Username:"></Control>
<Control name="lblpassword" text="Password:"></Control>
<Control name="lbllanguage" text="Language:"></Control>
<Control name="btnlogon" text="Logon"></Control>
<Control name="btncancel" text="Exit"></Control>
<Control name="btnchangepwd" text="Change Password"></Control>
</Controls>
</Form>
<Form>
<Name>FrmPasswordChange</Name>
<Controls>
<Control name="frmpasswordchange" text="Change
password"></Control>
<Control name="lblusername" text="Username:"></Control>
<Control name="lblpassword" text="Old Password:"></Control>
<Control name="lblnewpassword" text="New Password:"></Control>
<Control name="lblpasswordconfirm" text="Password
Confirm:"></Control>
<Control name="btnok" text="OK"></Control>
<Control name="btncancel" text="Return"></Control>
</Controls>
</Form>
<Form>
<Name>SecondForm</Name>
<Controls>
<Control name="SecondForm" text="Second Form"></Control>
<Control name="dgvSeconder" text="dgvSeconder"></Control>
</Controls>
</Form>
<Form>
<Name>dgvSeconder</Name>
<Controls>
<Control name="ID" text="ID"></Control>
<Control name="NAME" text="NAME"></Control>
</Controls>
</Form>
</Resource>
和
AppResource_TH.xml
<?xml version="1.0" encoding="utf-8" ?>
<Resource>
<Form>
<Name>frmlogon</Name>
<Controls>
<Control name="frmlogon" text="登錄"></Control>
<Control name="lblusername" text="用戶名:"></Control>
<Control name="lblpassword" text="密 碼:"></Control>
<Control name="lbllanguage" text="語 言:"></Control>
<Control name="btnlogon" text="登 錄"></Control>
<Control name="btncancel" text="退 出"></Control>
<Control name="btnchangepwd" text="更改密碼"></Control>
</Controls>
</Form>
<Form>
<Name>FrmPasswordChange</Name>
<Controls>
<Control name="frmpasswordchange" text="更改密码"></Control>
<Control name="lblusername" text="用戶名:"></Control>
<Control name="lblpassword" text="舊密碼:"></Control>
<Control name="lblnewpassword" text="新密碼:"></Control>
<Control name="lblpasswordconfirm" text="提 交"></Control>
<Control name="btnok" text="確 定"></Control>
<Control name="btncancel" text="返 回"></Control>
</Controls>
</Form>
<Form>
<Name>SecondForm</Name>
<Controls>
<Control name="SecondForm" text="第二窗體"></Control>
<Control name="dgvSeconder" text="數據表格"></Control>
</Controls>
</Form>
<Form>
<Name>dgvSeconder</Name>
<Controls>
<Control name="ID" text="序號"></Control>
<Control name="NAME" text="姓名"></Control>
</Controls>
</Form>
</Resource>
和
AppResource_ZH.xml
<?xml version="1.0" encoding="utf-8" ?>
<Resource>
<Form>
<Name>frmlogon</Name>
<Controls>
<Control name="frmlogon" text="登录"></Control>
<Control name="lblusername" text="用户名:"></Control>
<Control name="lblpassword" text="密 码:"></Control>
<Control name="lbllanguage" text="语 言:"></Control>
<Control name="btnlogon" text="登 录"></Control>
<Control name="btncancel" text="退 出"></Control>
<Control name="btnchangepwd" text="更改密码"></Control>
</Controls>
</Form>
<Form>
<Name>FrmPasswordChange</Name>
<Controls>
<Control name="frmpasswordchange" text="更改密码"></Control>
<Control name="lblusername" text="用户名:"></Control>
<Control name="lblpassword" text="旧密码:"></Control>
<Control name="lblnewpassword" text="新密码:"></Control>
<Control name="lblpasswordconfirm" text="提 交"></Control>
<Control name="btnok" text="确 定"></Control>
<Control name="btncancel" text="返 回"></Control>
</Controls>
</Form>
<Form>
<Name>SecondForm</Name>
<Controls>
<Control name="SecondForm" text="第二窗体"></Control>
<Control name="dgvSeconder" text="数据表格"></Control>
</Controls>
</Form>
<Form>
<Name>dgvSeconder</Name>
<Controls>
<Control name="ID" text="序号"></Control>
<Control name="NAME" text="姓名"></Control>
</Controls>
</Form>
</Resource>
接着定义一个窗体
frmlogon.cs
LanguageDefine.xml
PublishClass.cs
SecondForm.cs
Test.cs
后续的类如有需要者请联系
QQ:383638323