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

using INT69DB_2A.Forms;

namespace INT69DB_2A.DialogForms
{
    public partial class DialogFormMessage : Form
    {
        #region Field
        private FormMain m_ParentForm;
        #endregion

        #region Constructor
        public DialogFormMessage()
        {
            InitializeComponent();
        }
        public DialogFormMessage(string str, DataStore.LanguageID language, string code)
        {
            InitializeComponent();

            this.labelErrorCode.Text = code;
            this.labelMessage1.Text = "";
            this.labelMessage2.Text = "";

            switch (language)
            {
                case DataStore.LanguageID.Korean:
                    this.labelMessage1.Text = str + "개의 파일이 백업되었습니다.";
                    break;
                case DataStore.LanguageID.English:
                    this.labelMessage1.Text = str + " files are backed up";
                    break;
                case DataStore.LanguageID.Chinese:
                    this.buttonOK.Text = "好";
                    this.labelMessage1.Text = str + " 个文件已备份";
                    break;
                case DataStore.LanguageID.Japanese:
                    this.labelMessage1.Text = str + "個のファイルがバックアップされました";
                    break;
                case DataStore.LanguageID.Czech:
                    this.labelMessage1.Text = "Těchto " + str + " soubory byly zálohovány.";
                    break;
                case DataStore.LanguageID.German:
                    break;
                case DataStore.LanguageID.Russian:
                    break;
                default:
                    this.labelMessage1.Text = str + "개의 파일이 백업되었습니다.";
                    break;
            }
        }
        // 01
        public DialogFormMessage(int code, DataStore.LanguageID language)
        {
            InitializeComponent();

            this.labelErrorCode.Text = "";
            this.labelMessage1.Text = "";
            this.labelMessage2.Text = "";

            if (language == DataStore.LanguageID.Korean)
            {
                this.buttonOK.Text = "OK";

                #region 한글
                switch (code)
                {
                    case 1:
                        this.labelErrorCode.Text = "Error 01_01";
                        this.labelMessage1.Text = "입력범위를 확인하세요.";
                        break;
                    case 2:
                        this.labelErrorCode.Text = "Error 01_02";
                        this.labelMessage1.Text = "최신 프로그램입니다.";
                        break;
                    case 3:
                        this.labelErrorCode.Text = "Error 01_03";
                        this.labelMessage1.Text = "연속으로 불량이 발생했습니다";
                        break;
                    case 4:
                        this.labelErrorCode.Text = "Error 01_04";
                        this.labelMessage1.Text = "백업할 파일이 없습니다";
                        break;
                    case 5:
                        this.labelErrorCode.Text = "Error 01_05";
                        this.labelMessage1.Text = "USB메모리가 장착되지 않았습니다";
                        break;
                    case 6:
                        this.labelErrorCode.Text = "Error 01_06";
                        this.labelMessage1.Text = "제조사에 문의하세요";
                        break;
                    case 7:
                        this.labelErrorCode.Text = "Error 01_07";
                        this.labelMessage1.Text = "USB에 업데이트 할 파일이 없습니다";
                        break;
                    case 8:
                        this.labelErrorCode.Text = "Error 01_08";
                        this.labelMessage1.Text = "업데이트 할 실행파일 개수가 많습니다";
                        break;
                    case 9:
                        this.labelErrorCode.Text = "Error 01_09";
                        this.labelMessage1.Text = "USB에 업데이트 폴더가 없습니다";
                        break;
                    case 10:
                        this.labelErrorCode.Text = "Error 01_10";
                        this.labelMessage1.Text = "해당 메모리가 장착되지 않았습니다";
                        break;
                    case 11:
                        this.labelErrorCode.Text = "Error 01_11";
                        this.labelMessage1.Text = "입력센서 에러에 의해 정지하였습니다.";
                        break;
                    case 12:
                        this.labelErrorCode.Text = "Error 01_12";
                        this.labelMessage1.Text = "적체박스를 비워 주세요.";
                        this.labelMessage2.Text = "";
                        break;
                    case 13:
                        break;
                    case 14:
                        break;
                    case 15:
                        this.labelErrorCode.Text = "Error 01_15";
                        this.labelMessage1.Text = "가져올 파일이 없습니다";
                        this.labelMessage2.Text = "";
                        break;
                    case 16:
                        this.labelErrorCode.Text = "Error 01_16";
                        this.labelMessage1.Text = "에러 발생! 다시 시도해주세요";
                        this.labelMessage2.Text = "";
                        break;
                    case 17:
                        this.labelErrorCode.Text = "Error 01_17";
                        this.labelMessage1.Text = "초기화를 실행해 주세요";
                        break;
                    case 18:
                        this.labelErrorCode.Text = "Info 18";
                        this.labelMessage1.Text = "전원을 끄고 다시 켜주세요";
                        break;
                    case 19:
                        this.labelErrorCode.Text = "Error 01_19";
                        this.labelMessage1.Text = "이 파일은 지원이 되지 않습니다";
                        break;
                    case 20:
                        break;
                    case 31:
                        this.labelErrorCode.Text = "Error 01_31";
                        this.labelMessage1.Text = "유저 파일 에러";
                        this.labelMessage2.Text = "";
                        break;
                    case 32:
                        this.labelErrorCode.Text = "Error 01_32";
                        this.labelMessage1.Text = "ID 확인하세요";
                        this.labelMessage2.Text = "";
                        break;
                    case 33:
                        this.labelErrorCode.Text = "Error 01_33";
                        this.labelMessage1.Text = "Password 확인하세요";
                        this.labelMessage2.Text = "";
                        break;
                    case 34:
                        this.labelErrorCode.Text = "Error 01_34";
                        this.labelMessage1.Text = "동일한 ID가 있습니다!";
                        this.labelMessage2.Text = "";
                        break;
                    case 35:
                        this.labelErrorCode.Text = "Error 01_35";
                        this.labelMessage1.Text = "4~10자 입력 하세요!";
                        this.labelMessage2.Text = "";
                        break;
                    default:
                        this.labelErrorCode.Text = "Error 01_99";
                        this.labelMessage1.Text = "제조사에 문의하세요";
                        break;
                }
                #endregion
            }
            else if (language == DataStore.LanguageID.English)
            {
                this.buttonOK.Text = "OK";

                #region 영문
                switch (code)
                {
                    case 1:
                        this.labelErrorCode.Text = "Error 01_01";
                        this.labelMessage1.Text = "Confirm input range";
                        break;
                    case 2:
                        this.labelErrorCode.Text = "Error 01_02";
                        this.labelMessage1.Text = "Application is the lastest";
                        break;
                    case 3:
                        this.labelErrorCode.Text = "Error 01_03";
                        this.labelMessage1.Text = "Detect Continuous N.G !!";
                        break;
                    case 4:
                        this.labelErrorCode.Text = "Error 01_04";
                        this.labelMessage1.Text = "There are no Backup files";
                        break;
                    case 5:
                        this.labelErrorCode.Text = "Error 01_05";
                        this.labelMessage1.Text = "No USB Memory";
                        break;
                    case 6:
                        this.labelErrorCode.Text = "Error 01_06";
                        this.labelMessage1.Text = "Please contact a manufacturer";
                        break;
                    case 7:
                        this.labelErrorCode.Text = "Error 01_07";
                        this.labelMessage1.Text = "There are no update files in USB";
                        break;
                    case 8:
                        this.labelErrorCode.Text = "Error 01_08";
                        this.labelMessage1.Text = "Too much file for update";
                        break;
                    case 9:
                        this.labelErrorCode.Text = "Error 01_09";
                        this.labelMessage1.Text = "There is no folder has update files in USB";
                        break;
                    case 10:
                        this.labelErrorCode.Text = "Error 01_10";
                        this.labelMessage1.Text = "There is no MEMORY";
                        break;
                    case 11:
                        this.labelErrorCode.Text = "Error 01_11";
                        this.labelMessage1.Text = "Emergency stop due to entry sensor error";
                        break;
                    case 12:
                        this.labelErrorCode.Text = "Error 01_12";
                        this.labelMessage1.Text = "Please load the box blank";
                        this.labelMessage2.Text = "";
                        break;
                    case 13:
                        break;
                    case 14:
                        break;
                    case 15:
                        this.labelErrorCode.Text = "Error 01_15";
                        this.labelMessage1.Text = "There are no files to be imported";
                        this.labelMessage2.Text = "";
                        break;
                    case 16:
                        this.labelErrorCode.Text = "Error 01_16";
                        this.labelMessage1.Text = "Error 01_01_occured! Try again";
                        this.labelMessage2.Text = "";
                        break;
                    case 17:
                        this.labelErrorCode.Text = "Error 01_17";
                        this.labelMessage1.Text = "Please run the initialization";
                        break;
                    case 18:
                        this.labelErrorCode.Text = "Info 18";
                        this.labelMessage1.Text = "Turn OFF the power";
                        this.labelMessage2.Text = "and then turn ON the power.";
                        break;
                    case 19:
                        this.labelErrorCode.Text = "Error 01_19";
                        this.labelMessage1.Text = "This file is not supported";
                        break;
                    case 20:
                        break;
                    case 31:
                        this.labelErrorCode.Text = "Error 01_31";
                        this.labelMessage1.Text = "User files error";
                        this.labelMessage2.Text = "";
                        break;
                    case 32:
                        this.labelErrorCode.Text = "Error 01_32";
                        this.labelMessage1.Text = "Check the ID";
                        this.labelMessage2.Text = "";
                        break;
                    case 33:
                        this.labelErrorCode.Text = "Error 01_33";
                        this.labelMessage1.Text = "Check the password";
                        this.labelMessage2.Text = "";
                        break;
                    case 34:
                        this.labelErrorCode.Text = "Error 01_34";
                        this.labelMessage1.Text = "The system already has the same ID";
                        this.labelMessage2.Text = "";
                        break;
                    case 35:
                        this.labelErrorCode.Text = "Error 01_35";
                        this.labelMessage1.Text = "Please enter 4-10 characters";
                        this.labelMessage2.Text = "";
                        break;
                    default:
                        this.labelErrorCode.Text = "Error 01_99";
                        this.labelMessage1.Text = "Please contact a manufacturer";
                        break;
                }
                #endregion
            }
            else if (language == DataStore.LanguageID.Chinese)
            {
                this.buttonOK.Text = "确认";

                #region 중문
                switch (code)
                {
                    case 1:
                        this.labelErrorCode.Text = "错误 01_01";
                        this.labelMessage1.Text = "确认输入范围";
                        break;
                    case 2:
                        this.labelErrorCode.Text = "错误 01_02";
                        this.labelMessage1.Text = "最近应用";
                        break;
                    case 3:
                        this.labelErrorCode.Text = "错误 01_03";
                        this.labelMessage1.Text = "测试连续NG";
                        break;
                    case 4:
                        this.labelErrorCode.Text = "错误 01_04";
                        this.labelMessage1.Text = "无支持文件";
                        break;
                    case 5:
                        this.labelErrorCode.Text = "错误 01_05";
                        this.labelMessage1.Text = "无USB存储卡";
                        break;
                    case 6:
                        this.labelErrorCode.Text = "错误 01_06";
                        this.labelMessage1.Text = "请联系厂商";
                        break;
                    case 7:
                        this.labelErrorCode.Text = "错误 01_07";
                        this.labelMessage1.Text = "USB无更新文件";
                        break;
                    case 8:
                        this.labelErrorCode.Text = "错误 01_08";
                        this.labelMessage1.Text = "太多文件需更新";
                        break;
                    case 9:
                        this.labelErrorCode.Text = "错误 01_09";
                        this.labelMessage1.Text = "USB没有文件夹需要更新文件다";
                        break;
                    case 10:
                        this.labelErrorCode.Text = "错误 01_10";
                        this.labelMessage1.Text = "无存储";
                        break;
                    case 11:
                        this.labelErrorCode.Text = "错误 01_11";
                        this.labelMessage1.Text = "由于进入传感器错误导致紧急停止";
                        break;
                    case 12:
                        this.labelErrorCode.Text = "错误 01_12";
                        this.labelMessage1.Text = "请清理箱子";
                        this.labelMessage2.Text = "";
                        break;
                    case 13:
                        break;
                    case 14:
                        break;
                    case 15:
                        this.labelErrorCode.Text = "错误 01_15";
                        this.labelMessage1.Text = "无文件导入";
                        this.labelMessage2.Text = "";
                        break;
                    case 16:
                        this.labelErrorCode.Text = "错误 01_16";
                        this.labelMessage1.Text = "错误发生，重试";
                        this.labelMessage2.Text = "";
                        break;
                    case 17:
                        this.labelErrorCode.Text = "错误 01_17";
                        this.labelMessage1.Text = "运行初始化";
                        break;
                    case 18:
                        this.labelErrorCode.Text = "信息 18";
                        this.labelMessage1.Text = "关掉电源，然后在打开电源";
                        break;
                    case 19:
                        this.labelErrorCode.Text = "錯誤 01_19";
                        this.labelMessage1.Text = "不支援这个档案";
                        break;
                    case 20:
                        break;
                    case 31:
                        this.labelErrorCode.Text = "错误 01_31";
                        this.labelMessage1.Text = "用户文件错误";
                        this.labelMessage2.Text = "";
                        break;
                    case 32:
                        this.labelErrorCode.Text = "错误 01_32";
                        this.labelMessage1.Text = "检查身份证";
                        this.labelMessage2.Text = "";
                        break;
                    case 33:
                        this.labelErrorCode.Text = "错误 01_33";
                        this.labelMessage1.Text = "检查密码";
                        this.labelMessage2.Text = "";
                        break;
                    case 34:
                        this.labelErrorCode.Text = "错误 01_34";
                        this.labelMessage1.Text = "系统已具有相同的ID";
                        this.labelMessage2.Text = "";
                        break;
                    case 35:
                        this.labelErrorCode.Text = "错误 01_35";
                        this.labelMessage1.Text = "请输入4-10个字符";
                        this.labelMessage2.Text = "";
                        break;
                    default:
                        this.labelErrorCode.Text = "错误 01_99";
                        this.labelMessage1.Text = "请联系厂商";
                        break;
                }
                #endregion
            }
            else if (language == DataStore.LanguageID.Japanese)
            {
                this.buttonOK.Text = "OK";

                #region 일본어
                switch (code)
                {
                    case 1:
                        this.labelErrorCode.Text = "エラㅡ 01_01";
                        this.labelMessage1.Text = "入力範囲を確認してください。";
                        break;
                    case 2:
                        this.labelErrorCode.Text = "エラㅡ 01_02";
                        this.labelMessage1.Text = "最新プログラムです。";
                        break;
                    case 3:
                        this.labelErrorCode.Text = "エラㅡ 01_03";
                        this.labelMessage1.Text = "連続NGを検出してください。";
                        break;
                    case 4:
                        this.labelErrorCode.Text = "エラㅡ 01_04";
                        this.labelMessage1.Text = "バックアップファイルがない。";
                        break;
                    case 5:
                        this.labelErrorCode.Text = "エラㅡ 01_05";
                        this.labelMessage1.Text = "USBメモリが装着されていません。";
                        break;
                    case 6:
                        this.labelErrorCode.Text = "エラㅡ 01_06";
                        this.labelMessage1.Text = "メㅡカㅡにお問い合わせください。";
                        break;
                    case 7:
                        this.labelErrorCode.Text = "エラㅡ 01_07";
                        this.labelMessage1.Text = "USBにアップデㅡトするファイルがありません。";
                        break;
                    case 8:
                        this.labelErrorCode.Text = "エラㅡ 01_08";
                        this.labelMessage1.Text = "更新する実行ファイルの数が多い";
                        break;
                    case 9:
                        this.labelErrorCode.Text = "エラㅡ 01_09";
                        this.labelMessage1.Text = "USBにアップデㅡトフォルダがありません。";
                        break;
                    case 10:
                        this.labelErrorCode.Text = "エラㅡ 01_10";
                        this.labelMessage1.Text = "対応するメモリが装着されていません。";
                        break;
                    case 11:
                        this.labelErrorCode.Text = "エラㅡ 01_11";
                        this.labelMessage1.Text = "入力センサエラㅡにより停止しました。";
                        break;
                    case 12:
                        this.labelErrorCode.Text = "エラㅡ 01_12";
                        this.labelMessage1.Text = "赤いボックスを空にしてください。";
                        this.labelMessage2.Text = "";
                        break;
                    case 13:
                        break;
                    case 14:
                        break;
                    case 15:
                        this.labelErrorCode.Text = "エラㅡ 01_15";
                        this.labelMessage1.Text = "インポㅡトするファイルがありません";
                        this.labelMessage2.Text = "";
                        break;
                    case 16:
                        this.labelErrorCode.Text = "エラㅡ 01_16";
                        this.labelMessage1.Text = "エラㅡ発生！もう一度お試しください。";
                        this.labelMessage2.Text = "";
                        break;
                    case 17:
                        this.labelErrorCode.Text = "エラㅡ 01_17";
                        this.labelMessage1.Text = "初期化を実行してください。";
                        break;
                    case 18:
                        this.labelErrorCode.Text = "インフォメㅡション 18";
                        this.labelMessage1.Text = "電源を再起動してください。";
                        break;
                    case 19:
                        this.labelErrorCode.Text = "エラㅡ 01_19";
                        this.labelMessage1.Text = "このファイルはサポㅡトされていません";
                        break;
                    case 20:
                        break;
                    case 31:
                        this.labelErrorCode.Text = "エラㅡ 01_31";
                        this.labelMessage1.Text = "ユㅡザㅡファイルエラㅡ";
                        this.labelMessage2.Text = "";
                        break;
                    case 32:
                        this.labelErrorCode.Text = "エラㅡ 01_32";
                        this.labelMessage1.Text = "IDを確認してください。";
                        this.labelMessage2.Text = "";
                        break;
                    case 33:
                        this.labelErrorCode.Text = "エラㅡ 01_33";
                        this.labelMessage1.Text = "パスワㅡドを確認してください。";
                        this.labelMessage2.Text = "";
                        break;
                    case 34:
                        this.labelErrorCode.Text = "エラㅡ 01_34";
                        this.labelMessage1.Text = "同じIDがあります！";
                        this.labelMessage2.Text = "";
                        break;
                    case 35:
                        this.labelErrorCode.Text = "エラㅡ 01_35";
                        this.labelMessage1.Text = "4～10文字入力してください！";
                        this.labelMessage2.Text = "";
                        break;
                    default:
                        this.labelErrorCode.Text = "エラㅡ 01_99";
                        this.labelMessage1.Text = "メㅡカㅡにお問い合わせください。";
                        break;
                }
                #endregion
            }
            else if (language == DataStore.LanguageID.Czech)
            {
                this.buttonOK.Text = "OK";

                #region 체코어
                switch (code)
                {
                    case 1:
                        this.labelErrorCode.Text = "Chybě 01_01";
                        this.labelMessage1.Text = "Potvrďte vstupní rozsah.";
                        break;
                    case 2:
                        this.labelErrorCode.Text = "Chybě 01_02";
                        this.labelMessage1.Text = "Aplikace je aktuální.";
                        break;
                    case 3:
                        this.labelErrorCode.Text = "Chybě 01_03";
                        this.labelMessage1.Text = "Detekce plynulosti N.G.";
                        break;
                    case 4:
                        this.labelErrorCode.Text = "Chybě 01_04";
                        this.labelMessage1.Text = "Neexistují žádné záložní soubory.";
                        break;
                    case 5:
                        this.labelErrorCode.Text = "Chybě 01_05";
                        this.labelMessage1.Text = "USB disk není připojen";
                        break;
                    case 6:
                        this.labelErrorCode.Text = "Chybě 01_06";
                        this.labelMessage1.Text = "Kontaktujte výrobce";
                        break;
                    case 7:
                        this.labelErrorCode.Text = "Chybě 01_07";
                        this.labelMessage1.Text = "Na USB disku nejsou";
                        this.labelMessage2.Text = "žádné aktualizační soubory";
                        break;
                    case 8:
                        this.labelErrorCode.Text = "Chybě 01_08";
                        this.labelMessage1.Text = "Příliš mnoho souboru k aktualizaci";
                        break;
                    case 9:
                        this.labelErrorCode.Text = "Chybě 01_09";
                        this.labelMessage1.Text = "Na USB disku není žádná";
                        this.labelMessage2.Text = "složka s aktualizačními soubory.";
                        break;
                    case 10:
                        this.labelErrorCode.Text = "Chybě 01_10";
                        this.labelMessage1.Text = "Není žádná PAMĚTI";
                        break;
                    case 11:
                        this.labelErrorCode.Text = "Chybě 01_11";
                        this.labelMessage1.Text = "Nouzové zastavení z důvodu chyby snímače vstupu";
                        break;
                    case 12:
                        this.labelErrorCode.Text = "Chybě 01_12";
                        this.labelMessage1.Text = "Vložte prosím krabici prázdnou";
                        this.labelMessage2.Text = "";
                        break;
                    case 13:
                        break;
                    case 14:
                        break;
                    case 15:
                        this.labelErrorCode.Text = "Chybě 01_15";
                        this.labelMessage1.Text = "Nejsou žádné soubory k importu";
                        this.labelMessage2.Text = "";
                        break;
                    case 16:
                        this.labelErrorCode.Text = "Chybě 01_16";
                        this.labelMessage1.Text = "Vyskytla se chyba! Zkus to znovu";
                        this.labelMessage2.Text = "";
                        break;
                    case 17:
                        this.labelErrorCode.Text = "Chybě 01_17";
                        this.labelMessage1.Text = "Spusťte inicializaci";
                        break;
                    case 18:
                        this.labelErrorCode.Text = "informace 18";
                        this.labelMessage1.Text = "Nejprve zařízení";
                        this.labelMessage2.Text = "vypněte a pak opět zapněte.";
                        break;
                    case 19:
                        this.labelErrorCode.Text = "Chybě 01_19";
                        this.labelMessage1.Text = "Tento soubor není podporován";
                        break;
                    case 20:
                        break;
                    case 31:
                        this.labelErrorCode.Text = "Chybě 01_31";
                        this.labelMessage1.Text = "Chyba souborů uživatele";
                        this.labelMessage2.Text = "";
                        break;
                    case 32:
                        this.labelErrorCode.Text = "Chybě 01_32";
                        this.labelMessage1.Text = "Zkontrolujte ID";
                        this.labelMessage2.Text = "";
                        break;
                    case 33:
                        this.labelErrorCode.Text = "Chybě 01_33";
                        this.labelMessage1.Text = "Zkontrolujte heslo";
                        this.labelMessage2.Text = "";
                        break;
                    case 34:
                        this.labelErrorCode.Text = "Chybě 01_34";
                        this.labelMessage1.Text = "Systém již má stejné ID";
                        this.labelMessage2.Text = "";
                        break;
                    case 35:
                        this.labelErrorCode.Text = "Chybě 01_35";
                        this.labelMessage1.Text = "Zadejte 4–10 znaků";
                        this.labelMessage2.Text = "";
                        break;
                    default:
                        this.labelErrorCode.Text = "Chybě 01_99";
                        this.labelMessage1.Text = "Kontaktujte výrobce";
                        break;
                }
                #endregion
            }
            else
            {

            }
        }
        // 02
        public DialogFormMessage(int code, DataStore.LanguageID language, string data)
        {
            InitializeComponent();

            this.labelErrorCode.Text = "";
            this.labelMessage1.Text = "";
            if (data != "")
                this.labelMessage2.Text = data;
            else
                this.labelMessage2.Text = "";

            if (language == DataStore.LanguageID.Korean)
            {
                this.buttonOK.Text = "OK";

                #region 한글
                switch (code)
                {
                    case 1:
                        this.labelErrorCode.Text = "Error 02_01";
                        this.labelMessage1.Text = "입력범위를 확인하세요.";
                        this.labelMessage2.Text = data;
                        break;
                    default:
                        this.labelErrorCode.Text = "Error 02_99";
                        this.labelMessage1.Text = "제조사에 문의하세요";
                        break;
                }
                #endregion
            }
            else if (language == DataStore.LanguageID.English)
            {
                this.buttonOK.Text = "OK";
                
                #region 영문
                switch (code)
                {
                    case 1:
                        this.labelErrorCode.Text = "Error 02_01";
                        this.labelMessage1.Text = "Confirm input range";
                        break;
                    default:
                        this.labelErrorCode.Text = "Error 02_99";
                        this.labelMessage1.Text = "Please contact a manufacturer";
                        break;
                }
                #endregion
            }
            else if (language == DataStore.LanguageID.Chinese)
            {
                this.buttonOK.Text = "确认";

                #region 중문
                switch (code)
                {
                    case 1:
                        this.labelErrorCode.Text = "错误 02_01";
                        this.labelMessage1.Text = "确认输入范围";
                        break;
                    default:
                        this.labelErrorCode.Text = "错误 02_99";
                        this.labelMessage1.Text = "请联系厂商";
                        break;
                }
                #endregion
            }
            else if (language == DataStore.LanguageID.Japanese)
            {
                this.buttonOK.Text = "OK";

                #region 일본어
                switch (code)
                {
                    case 1:
                        this.labelErrorCode.Text = "エラㅡ 02_01";
                        this.labelMessage1.Text = "入力範囲を確認してください。";
                        this.labelMessage2.Text = data;
                        break;
                    default:
                        this.labelErrorCode.Text = "エラㅡ 02_99";
                        this.labelMessage1.Text = "メㅡカㅡにお問い合わせください。";
                        break;
                }
                #endregion
            }
            else if (language == DataStore.LanguageID.Czech)
            {
                this.buttonOK.Text = "OK";

                #region 체코어
                switch (code)
                {
                    case 1:
                        this.labelErrorCode.Text = "Chybě 02_01";
                        this.labelMessage1.Text = "Potvrďte vstupní rozsah.";
                        break;
                    default:
                        this.labelErrorCode.Text = "Chybě 02_99";
                        this.labelMessage1.Text = "Kontaktujte výrobce";
                        break;
                }
                #endregion
            }
            else
            {

            }
        }
        // 04
        public DialogFormMessage(object dll, int code, DataStore.LanguageID language)
        {
            InitializeComponent();

            this.labelErrorCode.Text = "";
            this.labelMessage1.Text = "";
            this.labelMessage2.Text = "";

            switch (language)
            {
                case DataStore.LanguageID.Korean:
                    #region 한글
                    switch (code)
                    {
                        case 1:
                            this.labelErrorCode.Text = "Error 04_01";
                            this.labelMessage1.Text = "ID를 찾을 수 없습니다";
                            break;
                        case 2:
                            this.labelErrorCode.Text = "Error 04_02";
                            this.labelMessage1.Text = "ID : 동일한 ID가 있습니다";
                            break;
                        case 3:
                            this.labelErrorCode.Text = "Error 04_03";
                            this.labelMessage1.Text = "ID : 6~20자 입력하세요";
                            break;
                        case 4:
                            this.labelErrorCode.Text = "Error 04_04";
                            this.labelMessage1.Text = "ID : 6~20자 입력하세요";
                            break;
                        case 5:
                            this.labelErrorCode.Text = "Error 04_05";
                            this.labelMessage1.Text = "ID : 연속된 문자(123,321,abc,cba...)또는";
                            this.labelMessage2.Text = "동일한 문자(111,222,aaa...) 사용 할 수 없습니다";
                            break;
                        case 6:
                            this.labelErrorCode.Text = "Error 04_06";
                            this.labelMessage1.Text = "ID : 사용할 수 없는 문자가 포함되어 있습니다";
                            break;
                        case 7:
                            this.labelErrorCode.Text = "Error 04_07";
                            this.labelMessage1.Text = "ID : 사용자 계정이 만료 되었습니다";
                            break;
                        case 8:
                            this.labelErrorCode.Text = "Error 04_08";
                            this.labelMessage1.Text = "PASSWORD : 이전 패스워드 입니다";
                            break;
                        case 9:
                            this.labelErrorCode.Text = "Error 04_09";
                            this.labelMessage1.Text = "PASSWORD : 6~20자 입력하세요";
                            break;
                        case 10:
                            this.labelErrorCode.Text = "Error 04_10";
                            this.labelMessage1.Text = "PASSWORD : 6~20자 입력하세요";
                            break;
                        case 11:
                            this.labelErrorCode.Text = "Error 04_11";
                            this.labelMessage1.Text = "PASSWORD : 연속된 문자(123,321,abc,cba...)또는";
                            this.labelMessage2.Text = "동일한 문자(111,222,aaa...) 사용 할 수 없습니다";
                            break;
                        case 12:
                            this.labelErrorCode.Text = "Error 04_12";
                            this.labelMessage1.Text = "PASSWORD : 사용할 수 없는 문자가 포함되어 있습니다";
                            this.labelMessage2.Text = "사용 가능 특수문자 : !@#$%^&*+-.";
                            break;
                        case 13:
                            this.labelErrorCode.Text = "Error 04_13";
                            this.labelMessage1.Text = "PASSWORD : 영문1이상, 숫자1이상, 특수문자1이상";
                            this.labelMessage2.Text = "포함하여 주십시오";
                            break;
                        case 14:
                            this.labelErrorCode.Text = "Error 04_14";
                            this.labelMessage1.Text = "비밀번호를 확인하세요";
                            break;
                        case 15:
                            this.labelErrorCode.Text = "Error 04_15";
                            this.labelMessage1.Text = "PASSWORD : 비밀번호가 만료 되었습니다";
                            break;
                        case 16:
                            this.labelErrorCode.Text = "Error 04_16";
                            this.labelMessage1.Text = "접근 권한을 설정해 주십시오";
                            break;
                        case 17:
                            this.labelErrorCode.Text = "Error 04_17";
                            this.labelMessage1.Text = "비밀번호가 동일하지 않습니다";
                            break;
                        case 18:
                            this.labelErrorCode.Text = "Error 04_18";
                            this.labelMessage1.Text = "";
                            break;
                        case 99:
                            this.labelErrorCode.Text = "Error 04_99";
                            this.labelMessage1.Text = "제조사에 문의하세요";
                            break;
                        default:
                            this.labelErrorCode.Text = "Error 04_99";
                            this.labelMessage1.Text = "제조사에 문의하세요";
                            break;
                    }
                    #endregion
                    break;
                case DataStore.LanguageID.English:
                    #region 영문
                    switch (code)
                    {
                        case 1:
                            this.labelErrorCode.Text = "Error 04_01";
                            this.labelMessage1.Text = "ID not found";
                            break;
                        case 2:
                            this.labelErrorCode.Text = "Error 04_02";
                            this.labelMessage1.Text = "ID : ID already exists";
                            break;
                        case 3:
                            this.labelErrorCode.Text = "Error 04_03";
                            this.labelMessage1.Text = "ID : Please enter 6~20 characters";
                            break;
                        case 4:
                            this.labelErrorCode.Text = "Error 04_04";
                            this.labelMessage1.Text = "ID : Please enter 6~20 characters";
                            break;
                        case 5:
                            this.labelErrorCode.Text = "Error 04_05";
                            this.labelMessage1.Text = "ID : Consecutive(123,321,abc,cba...) or";
                            this.labelMessage2.Text = "identical(111,222,aaa...) characters cannot be used.";
                            break;
                        case 6:
                            this.labelErrorCode.Text = "Error 04_06";
                            this.labelMessage1.Text = "ID : Contains invalid characters";
                            break;
                        case 7:
                            this.labelErrorCode.Text = "Error 04_07";
                            this.labelMessage1.Text = "ID : User account has expired";
                            break;
                        case 8:
                            this.labelErrorCode.Text = "Error 04_08";
                            this.labelMessage1.Text = "PASSWORD : This is the old password";
                            break;
                        case 9:
                            this.labelErrorCode.Text = "Error 04_09";
                            this.labelMessage1.Text = "PASSWORD : Please enter 6~20 characters";
                            break;
                        case 10:
                            this.labelErrorCode.Text = "Error 04_10";
                            this.labelMessage1.Text = "PASSWORD : Please enter 6~20 characters";
                            break;
                        case 11:
                            this.labelErrorCode.Text = "Error 04_11";
                            this.labelMessage1.Text = "PASSWORD : Consecutive(123,321,abc,cba...) or";
                            this.labelMessage2.Text = "identical(111,222,aaa...) characters cannot be used.";
                            break;
                        case 12:
                            this.labelErrorCode.Text = "Error 04_12";
                            this.labelMessage1.Text = "PASSWORD : Contains invalid characters";
                            this.labelMessage2.Text = "Special characters allowed : !@#$%^&*+-.";
                            break;
                        case 13:
                            this.labelErrorCode.Text = "Error 04_13";
                            this.labelMessage1.Text = "PASSWORD : Please include at least one English letter,";
                            this.labelMessage2.Text = "at least one number, and at least one special character";
                            break;
                        case 14:
                            this.labelErrorCode.Text = "Error 04_14";
                            this.labelMessage1.Text = "Check your password";
                            break;
                        case 15:
                            this.labelErrorCode.Text = "Error 04_15";
                            this.labelMessage1.Text = "PASSWORD : Password has expired";
                            break;
                        case 16:
                            this.labelErrorCode.Text = "Error 04_16";
                            this.labelMessage1.Text = "Please set the access right";
                            break;
                        case 17:
                            this.labelErrorCode.Text = "Error 04_17";
                            this.labelMessage1.Text = "Passwords are not the same";
                            break;
                        case 18:
                            this.labelErrorCode.Text = "Error 04_18";
                            this.labelMessage1.Text = "";
                            break;
                        case 99:
                            this.labelErrorCode.Text = "Error 04_99";
                            this.labelMessage1.Text = "Please contact a manufacturer";
                            break;
                        default:
                            this.labelErrorCode.Text = "Error 04_99";
                            this.labelMessage1.Text = "Please contact a manufacturer";
                            break;
                    }
                    #endregion
                    break;
                case DataStore.LanguageID.Chinese:
                    #region 중문
                    this.buttonOK.Text = "确认";

                    switch (code)
                    {
                        case 1:
                            this.labelErrorCode.Text = "错误 04_01";
                            this.labelMessage1.Text = "未找到 ID";
                            break;
                        case 2:
                            this.labelErrorCode.Text = "错误 04_02";
                            this.labelMessage1.Text = "ID : ID已存在";
                            break;
                        case 3:
                            this.labelErrorCode.Text = "错误 04_03";
                            this.labelMessage1.Text = "ID : 请输入6~20个字符";
                            break;
                        case 4:
                            this.labelErrorCode.Text = "错误 04_04";
                            this.labelMessage1.Text = "ID : 请输入6~20个字符";
                            break;
                        case 5:
                            this.labelErrorCode.Text = "错误 04_05";
                            this.labelMessage1.Text = "ID : 不能使用连续的 (123,321,abc,cba...)";
                            this.labelMessage2.Text = "或相同的 (111,222,aaa...) 字符。";
                            break;
                        case 6:
                            this.labelErrorCode.Text = "错误 04_06";
                            this.labelMessage1.Text = "ID : 它包含无效字符";
                            break;
                        case 7:
                            this.labelErrorCode.Text = "错误 04_07";
                            this.labelMessage1.Text = "ID : 用户帐号已过期";
                            break;
                        case 8:
                            this.labelErrorCode.Text = "错误 04_08";
                            this.labelMessage1.Text = "密码 : 这是旧密码";
                            break;
                        case 9:
                            this.labelErrorCode.Text = "错误 04_09";
                            this.labelMessage1.Text = "密码 : 请输入6~20个字符";
                            break;
                        case 10:
                            this.labelErrorCode.Text = "错误 04_10";
                            this.labelMessage1.Text = "密码 : 请输入6~20个字符";
                            break;
                        case 11:
                            this.labelErrorCode.Text = "错误 04_11";
                            this.labelMessage1.Text = "密码 : 不能使用连续的 (123,321,abc,cba...)";
                            this.labelMessage2.Text = "或相同的 (111,222,aaa...) 字符。";
                            break;
                        case 12:
                            this.labelErrorCode.Text = "错误 04_12";
                            this.labelMessage1.Text = "密码 : 它包含无效字符";
                            this.labelMessage2.Text = "允许使用特殊字符 : !@#$%^&*+-.";
                            break;
                        case 13:
                            this.labelErrorCode.Text = "错误 04_13";
                            this.labelMessage1.Text = "密码 : 请至少包含一个英文字母，";
                            this.labelMessage2.Text = "至少一个数字，至少一个特殊字符";
                            break;
                        case 14:
                            this.labelErrorCode.Text = "错误 04_14";
                            this.labelMessage1.Text = "检查您的密码";
                            break;
                        case 15:
                            this.labelErrorCode.Text = "错误 04_15";
                            this.labelMessage1.Text = "密码 : 密码已过期";
                            break;
                        case 16:
                            this.labelErrorCode.Text = "错误 04_16";
                            this.labelMessage1.Text = "请设置访问权限";
                            break;
                        case 17:
                            this.labelErrorCode.Text = "错误 04_17";
                            this.labelMessage1.Text = "密码不一样";
                            break;
                        case 18:
                            this.labelErrorCode.Text = "错误 04_18";
                            this.labelMessage1.Text = "";
                            break;
                        case 99:
                            this.labelErrorCode.Text = "错误 04_99";
                            this.labelMessage1.Text = "请联系制造商";
                            break;
                        default:
                            this.labelErrorCode.Text = "错误 04_99";
                            this.labelMessage1.Text = "请联系制造商";
                            break;
                    }
                    #endregion
                    break;
                case DataStore.LanguageID.Japanese:
                    #region 일본어
                    switch (code)
                    {
                        case 1:
                            this.labelErrorCode.Text = "エラㅡ 04_01";
                            this.labelMessage1.Text = "IDが見つかりません。";
                            break;
                        case 2:
                            this.labelErrorCode.Text = "エラㅡ 04_02";
                            this.labelMessage1.Text = "ID：同じIDがあります。";
                            break;
                        case 3:
                            this.labelErrorCode.Text = "エラㅡ 04_03";
                            this.labelMessage1.Text = "ID：6~20文字を入力してください。";
                            break;
                        case 4:
                            this.labelErrorCode.Text = "エラㅡ 04_04";
                            this.labelMessage1.Text = "ID：6~20文字を入力してください。";
                            break;
                        case 5:
                            this.labelErrorCode.Text = "エラㅡ 04_05";
                            this.labelMessage1.Text = "ID : 連続した文字(123,321,abc,cba...)";
                            this.labelMessage2.Text = "または同じ文字(111,222,aaa...)は使用できません。";
                            break;
                        case 6:
                            this.labelErrorCode.Text = "エラㅡ 04_06";
                            this.labelMessage1.Text = "ID：使用できない文字が含まれています。";
                            break;
                        case 7:
                            this.labelErrorCode.Text = "エラㅡ 04_07";
                            this.labelMessage1.Text = "ID：ユㅡザㅡアカウントの有効期限が切れました。";
                            break;
                        case 8:
                            this.labelErrorCode.Text = "エラㅡ 04_08";
                            this.labelMessage1.Text = "PASSWORD：以前のパスワㅡドです。";
                            break;
                        case 9:
                            this.labelErrorCode.Text = "エラㅡ 04_09";
                            this.labelMessage1.Text = "PASSWORD：6〜20文字を入力してください。";
                            break;
                        case 10:
                            this.labelErrorCode.Text = "エラㅡ 04_10";
                            this.labelMessage1.Text = "PASSWORD：6〜20文字を入力してください。";
                            break;
                        case 11:
                            this.labelErrorCode.Text = "エラㅡ 04_11";
                            this.labelMessage1.Text = "PASSWORD：連続した文字（123,321、abc、cba ...）";
                            this.labelMessage2.Text = "または同じ文字（111,222、aaa ...）を使用できません。";
                            break;
                        case 12:
                            this.labelErrorCode.Text = "エラㅡ 04_12";
                            this.labelMessage1.Text = "PASSWORD：使用できない文字が含まれています。";
                            this.labelMessage2.Text = "利用可能な特殊文字：！@#$%^&*+-.";
                            break;
                        case 13:
                            this.labelErrorCode.Text = "エラㅡ 04_13";
                            this.labelMessage1.Text = "PASSWORD：英文1以上、数字1以上、特殊文字";
                            this.labelMessage2.Text = "1以上含めてください。";
                            break;
                        case 14:
                            this.labelErrorCode.Text = "エラㅡ 04_14";
                            this.labelMessage1.Text = "パスワㅡドを確認してください。";
                            break;
                        case 15:
                            this.labelErrorCode.Text = "エラㅡ 04_15";
                            this.labelMessage1.Text = "PASSWORD：パスワㅡドが期限切れです。";
                            break;
                        case 16:
                            this.labelErrorCode.Text = "エラㅡ 04_16";
                            this.labelMessage1.Text = "アクセス権を設定してください。";
                            break;
                        case 17:
                            this.labelErrorCode.Text = "エラㅡ 04_17";
                            this.labelMessage1.Text = "パスワㅡドが同じではありません。";
                            break;
                        case 18:
                            this.labelErrorCode.Text = "エラㅡ 04_18";
                            this.labelMessage1.Text = "";
                            break;
                        case 99:
                            this.labelErrorCode.Text = "エラㅡ 04_99";
                            this.labelMessage1.Text = "メㅡカㅡにお問い合わせください。";
                            break;
                        default:
                            this.labelErrorCode.Text = "エラㅡ 04_99";
                            this.labelMessage1.Text = "メㅡカㅡにお問い合わせください。";
                            break;
                    }
                    #endregion
                    break;
                case DataStore.LanguageID.Czech:
                    #region 체코어
                    switch (code)
                    {
                        case 1:
                            this.labelErrorCode.Text = "Chybě 04_01";
                            this.labelMessage1.Text = "";
                            break;
                        case 2:
                            this.labelErrorCode.Text = "Chybě 04_02";
                            this.labelMessage1.Text = "";
                            break;
                        case 3:
                            this.labelErrorCode.Text = "Chybě 04_03";
                            this.labelMessage1.Text = "";
                            break;
                        case 4:
                            this.labelErrorCode.Text = "Chybě 04_04";
                            this.labelMessage1.Text = "";
                            break;
                        case 5:
                            this.labelErrorCode.Text = "Chybě 04_05";
                            this.labelMessage1.Text = "";
                            break;
                        case 6:
                            this.labelErrorCode.Text = "Chybě 04_06";
                            this.labelMessage1.Text = "";
                            break;
                        case 7:
                            this.labelErrorCode.Text = "Chybě 04_07";
                            this.labelMessage1.Text = "";
                            break;
                        case 8:
                            this.labelErrorCode.Text = "Chybě 04_08";
                            this.labelMessage1.Text = "";
                            break;
                        case 9:
                            this.labelErrorCode.Text = "Chybě 04_09";
                            this.labelMessage1.Text = "";
                            break;
                        case 10:
                            this.labelErrorCode.Text = "Chybě 04_10";
                            this.labelMessage1.Text = "";
                            break;
                        case 11:
                            this.labelErrorCode.Text = "Chybě 04_11";
                            this.labelMessage1.Text = "";
                            break;
                        case 12:
                            this.labelErrorCode.Text = "Chybě 04_12";
                            this.labelMessage1.Text = "";
                            break;
                        case 13:
                            this.labelErrorCode.Text = "Chybě 04_13";
                            this.labelMessage1.Text = "";
                            break;
                        case 14:
                            this.labelErrorCode.Text = "Chybě 04_14";
                            this.labelMessage1.Text = "";
                            break;
                        case 15:
                            this.labelErrorCode.Text = "Chybě 04_15";
                            this.labelMessage1.Text = "";
                            break;
                        case 16:
                            this.labelErrorCode.Text = "Chybě 04_16";
                            this.labelMessage1.Text = "";
                            break;
                        case 17:
                            this.labelErrorCode.Text = "Chybě 04_17";
                            this.labelMessage1.Text = "";
                            break;
                        case 18:
                            this.labelErrorCode.Text = "Chybě 04_18";
                            this.labelMessage1.Text = "";
                            break;
                        case 99:
                            this.labelErrorCode.Text = "Chybě 04_99";
                            this.labelMessage1.Text = "Kontaktujte výrobce";
                            break;
                        default:
                            this.labelErrorCode.Text = "Chybě 04_99";
                            this.labelMessage1.Text = "Kontaktujte výrobce";
                            this.labelMessage2.Text = "";
                            break;
                    }
                    #endregion
                    break;
                case DataStore.LanguageID.German:
                    #region 독일어
                    this.buttonOK.Text = "Bestätigen";

                    switch (code)
                    {
                        case 1:
                            this.labelErrorCode.Text = "Fehler 04_01";
                            this.labelMessage1.Text = "ID nicht gefunden";
                            break;
                        case 2:
                            this.labelErrorCode.Text = "Fehler 04_02";
                            this.labelMessage1.Text = "ID : ID existiert bereits";
                            break;
                        case 3:
                            this.labelErrorCode.Text = "Fehler 04_03";
                            this.labelMessage1.Text = "ID : Bitte geben Sie 6~20 Zeichen ein";
                            break;
                        case 4:
                            this.labelErrorCode.Text = "Fehler 04_04";
                            this.labelMessage1.Text = "ID : Bitte geben Sie 6~20 Zeichen ein";
                            break;
                        case 5:
                            this.labelErrorCode.Text = "Fehler 04_05";
                            this.labelMessage1.Text = "ID : Aufeinanderfolgende (123,321,abc,cba...)";
                            this.labelMessage2.Text = "oder identische (111,222,aaa...) Zeichen können nicht verwendet werden.";
                            break;
                        case 6:
                            this.labelErrorCode.Text = "Fehler 04_06";
                            this.labelMessage1.Text = "ID : Es enthält ungültige Zeichen";
                            break;
                        case 7:
                            this.labelErrorCode.Text = "Fehler 04_07";
                            this.labelMessage1.Text = "ID : Benutzerkonto ist abgelaufen";
                            break;
                        case 8:
                            this.labelErrorCode.Text = "Fehler 04_08";
                            this.labelMessage1.Text = "Passwort : Dies ist das alte Passwort";
                            break;
                        case 9:
                            this.labelErrorCode.Text = "Fehler 04_09";
                            this.labelMessage1.Text = "Passwort : Bitte geben Sie 6~20 Zeichen ein";
                            break;
                        case 10:
                            this.labelErrorCode.Text = "Fehler 04_10";
                            this.labelMessage1.Text = "Passwort : Bitte geben Sie 6~20 Zeichen ein";
                            break;
                        case 11:
                            this.labelErrorCode.Text = "Fehler 04_11";
                            this.labelMessage1.Text = "Passwort : Aufeinanderfolgende (123,321,abc,cba...)";
                            this.labelMessage2.Text = "oder identische (111,222,aaa...) Zeichen können nicht verwendet werden.";
                            break;
                        case 12:
                            this.labelErrorCode.Text = "Fehler 04_12";
                            this.labelMessage1.Text = "Passwort : Es enthält ungültige Zeichen";
                            this.labelMessage2.Text = "Sonderzeichen erlaubt : !@#$%^&*+-.";
                            break;
                        case 13:
                            this.labelErrorCode.Text = "Fehler 04_13";
                            this.labelMessage1.Text = "Passwort : Bitte geben Sie mindestens einen";
                            this.labelMessage2.Text = "englischen Buchstaben, mindestens eine Ziffer und mindestens ein Sonderzeichen an";
                            break;
                        case 14:
                            this.labelErrorCode.Text = "Fehler 04_14";
                            this.labelMessage1.Text = "Überprüfen Sie Ihr Passwort";
                            break;
                        case 15:
                            this.labelErrorCode.Text = "Fehler 04_15";
                            this.labelMessage1.Text = "Passwort : Passwort ist abgelaufen";
                            break;
                        case 16:
                            this.labelErrorCode.Text = "Fehler 04_16";
                            this.labelMessage1.Text = "Bitte legen Sie Zugriffsrechte fest";
                            break;
                        case 17:
                            this.labelErrorCode.Text = "Fehler 04_17";
                            this.labelMessage1.Text = "Passwörter sind nicht gleich";
                            break;
                        case 18:
                            this.labelErrorCode.Text = "Fehler 04_18";
                            this.labelMessage1.Text = "";
                            break;
                        case 99:
                            this.labelErrorCode.Text = "Fehler 04_99";
                            this.labelMessage1.Text = "Bitte wenden Sie sich an einen Hersteller";
                            break;
                        default:
                            this.labelErrorCode.Text = "Fehler 04_99";
                            this.labelMessage1.Text = "Bitte wenden Sie sich an einen Hersteller";
                            break;
                    }
                    #endregion
                    break;
                default:
                    break;
            }
        }
        public DialogFormMessage(int code, DataStore.LanguageID language, FormMain parent)
        {
            InitializeComponent();

            this.ParentForm = parent;

            this.labelErrorCode.Text = "";
            this.labelMessage1.Text = "";
            this.labelMessage2.Text = "";

            switch (language)
            {
                case DataStore.LanguageID.Korean:
                    #region 한글
                    switch (code)
                    {
                        case 11:
                            this.labelErrorCode.Text = "Error 11";
                            this.labelMessage1.Text = "입력센서 에러에 의해 정지하였습니다.";
                            break;
                        default:
                            this.labelErrorCode.Text = "Error 99";
                            this.labelMessage1.Text = "제조사에 문의하세요";
                            break;
                    }
                    #endregion
                    break;
                case DataStore.LanguageID.English:
                    #region 영문
                    switch (code)
                    {
                        case 11:
                            this.labelErrorCode.Text = "Error 11";
                            this.labelMessage1.Text = "Emergency stop due to entry sensor error";
                            break;
                        default:
                            this.labelErrorCode.Text = "Error 99";
                            this.labelMessage1.Text = "Please contact a manufacturer";
                            break;
                    }
                    #endregion
                    break;
                case DataStore.LanguageID.Chinese:
                    #region 중문
                    this.buttonOK.Text = "好";

                    switch (code)
                    {
                        case 11:
                            this.labelErrorCode.Text = "錯誤 11";
                            this.labelMessage1.Text = "由于进入传感器错误导致紧急停止";
                            break;
                        default:
                            this.labelErrorCode.Text = "錯誤 99";
                            this.labelMessage1.Text = "请联系厂商";
                            break;
                    }
                    #endregion
                    break;
                case DataStore.LanguageID.Czech:
                    #region 체코어
                    switch (code)
                    {
                        case 11:
                            this.labelErrorCode.Text = "Chybě 11";
                            this.labelMessage1.Text = "Nouzové zastavení z důvodu chyby snímače vstupu";
                            break;
                        default:
                            this.labelErrorCode.Text = "Chybě 99";
                            this.labelMessage1.Text = "Kontaktujte výrobce";
                            break;
                    }
                    #endregion
                    break;
                case DataStore.LanguageID.German:
                    #region 독일어
                    switch (code)
                    {
                        case 11:
                            this.labelErrorCode.Text = "Fehler 11";
                            this.labelMessage1.Text = "Notstopp aufgrund eines Eintrittssensorfehlers";
                            break;
                        default:
                            this.labelErrorCode.Text = "Fehler 99";
                            this.labelMessage1.Text = "Hersteller kontaktieren";
                            break;
                    }
                    #endregion
                    break;
                default:
                    #region 한글
                    switch (code)
                    {
                        case 11:
                            this.labelErrorCode.Text = "Error 11";
                            this.labelMessage1.Text = "입력센서 에러에 의해 정지하였습니다.";
                            break;
                        default:
                            this.labelErrorCode.Text = "Error 99";
                            this.labelMessage1.Text = "제조사에 문의하세요";
                            break;
                    }
                    #endregion
                    break;
            }
        }
        public DialogFormMessage(DataStore.MessageBoxIcon icon, string code, string message1, string message2, int autoClose_sec)
        {
            InitializeComponent();

            this.timerAutoClose.Enabled = false;

            switch (icon)
            {
                case DataStore.MessageBoxIcon.None:
                    this.pictureBoxAsterisk.Visible = false;
                    this.pictureBoxExclamation.Visible = false;
                    this.pictureBoxHand.Visible = false;
                    this.pictureBoxQuestion.Visible = false;
                    break;
                case DataStore.MessageBoxIcon.Hand:
                    this.pictureBoxAsterisk.Visible = false;
                    this.pictureBoxExclamation.Visible = false;
                    this.pictureBoxHand.Visible = true;
                    this.pictureBoxQuestion.Visible = false;
                    break;
                case DataStore.MessageBoxIcon.Question:
                    this.pictureBoxAsterisk.Visible = false;
                    this.pictureBoxExclamation.Visible = false;
                    this.pictureBoxHand.Visible = false;
                    this.pictureBoxQuestion.Visible = true;
                    break;
                case DataStore.MessageBoxIcon.Exclamation:
                    this.pictureBoxAsterisk.Visible = false;
                    this.pictureBoxExclamation.Visible = true;
                    this.pictureBoxHand.Visible = false;
                    this.pictureBoxQuestion.Visible = false;
                    break;
                case DataStore.MessageBoxIcon.Asterisk:
                    this.pictureBoxAsterisk.Visible = true;
                    this.pictureBoxExclamation.Visible = false;
                    this.pictureBoxHand.Visible = false;
                    this.pictureBoxQuestion.Visible = false;
                    break;
                default:
                    break;
            }

            this.labelErrorCode.Text = code;
            this.labelMessage1.Text = message1;
            this.labelMessage2.Text = message2;

            if (autoClose_sec != 0)
            {
                this.timerAutoClose.Interval = autoClose_sec * 1000;
                this.timerAutoClose.Enabled = true;
            }
        }
        #endregion

        #region Property
        public FormMain ParentForm
        {
            get { return this.m_ParentForm; }
            set { this.m_ParentForm = value; }
        }
        #endregion

        #region Method
        private void InitializeControl()
        {
            int x = 0, y = 0;

            x = Screen.PrimaryScreen.Bounds.Width / 2 - this.Size.Width / 2;
            y = Screen.PrimaryScreen.Bounds.Height / 2 - this.Size.Height / 2;

            this.Location = new Point(x, y);

            this.Size = new Size(450, 165);
        }
        #endregion

        #region Override Member
        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);

            this.InitializeControl();
        }
        #endregion

        #region Event Handler
        private void buttonOK_Click(object sender, EventArgs e)
        {
            this.DialogResult = DialogResult.OK;
            this.Close();
        }
        private void timerAutoClose_Tick(object sender, EventArgs e)
        {
            this.timerAutoClose.Enabled = false;
            this.DialogResult = DialogResult.OK;
            this.Close();
        }
        #endregion
    }
}