コード例 #1
0
 private void checkUpdateToolStripMenuItem_Click(object sender, EventArgs e)
 {
     CheckUpdate.ReturnIfSame           = true;
     checkUpdateToolStripMenuItem.Image = CheckUpdate.CheckIt();
     CheckUpdate.ReturnIfSame           = false;
     //checkUpdateToolStripMenuItem.Image = CheckUpdate.IcoUpdate;
 }
コード例 #2
0
        private void MainForm_Shown(object sender, EventArgs e)
        {
            FileInfo      IfExist  = new FileInfo(ConfigReaderWriter.CONFIG_FILE);
            DirectoryInfo DirExist = new DirectoryInfo(IfExist.DirectoryName);

            if (!(DirExist.Exists))
            {
                DirExist.Create();
            }
            FontSkinManager();
            if (!(IfExist.Exists))
            {
                Setting Frm = new Setting();
                Frm.ShowDialog(this);
            }
            VarGlobale.LoadParam();
            if (string.IsNullOrEmpty(VarGlobal.Password) == true)
            {
                Setting Frm = new Setting();
                Frm.ShowDialog(this);
            }
            CmBxPrjName.Items.Clear();
            CmBxPrjName.Items.AddRange(VarGlobale.SubProject.ToArray());
            CmBxPrjName.Text = VarGlobal.PrefixUserName;
            if (VarGlobale.AutoCheckUpdate == true)
            {
                checkUpdateToolStripMenuItem.Image = CheckUpdate.CheckIt();
                //checkUpdateToolStripMenuItem.Image = CheckUpdate.IcoUpdate;
            }
            try
            {
                if (File.Exists(VarGlobale.BookMarks))
                {
                    CmBxPrjName.AutoCompleteCustomSource = (AutoCompleteStringCollection)
                                                           GenericXmlSerializer.Deserialize(VarGlobale.BookMarks,
                                                                                            CmBxPrjName.AutoCompleteCustomSource.GetType());
                    foreach (string item in CmBxPrjName.AutoCompleteCustomSource)
                    {
                        AddABookmark(item);
                    }
                }
            }
            catch (Exception Ex)
            {
                if (!VarGlobal.LessVerbose)
                {
                    Console.WriteLine("{0}{1}{2}", Ex.Message, Environment.NewLine, Ex.StackTrace);
                }
            }
        }