void Readini() { try { string file = Path.Combine(Application.StartupPath, "Archselect.ini"); Writeini.Fileini = file; string user = Writeini.Readini("username", "user"); txtUser.Text = user; } catch {} }
private void toolStripDouGotoP_ButtonClick(object sender, EventArgs e) { string file = Path.Combine(Application.StartupPath, "ScanConfig.ini"); Writeini.Fileini = file; string sj = Writeini.Readini("ImageConten", "GoPage").ToString(); if (sj.Trim().Length > 0) { int p; bool b = int.TryParse(sj, out p); if (!b || p <= 0) { return; } p += Clscheck.CrrentPage; if (p <= Clscheck.MaxPage) { Himg._Gotopage(p); } } }