public DataApi get() { string db = GetDb(); JavaScriptSerializer js = new JavaScriptSerializer(); DataApi lists = js.Deserialize <DataApi>(db); return(lists); }
private void form1_Load(object sender, EventArgs e) { try { SetConfig(); Api api = new Api(); DataApi db = api.get(); SetData(db); } catch (Exception a) { MessageBox.Show(a.Message); } }
private void SetData(DataApi db) { SetFtpData(db.ftp); SetMstscData(db.mstsc); SetSshData(db.ssh); }