Esempio n. 1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Session["TarServerName"] != null &&
                Session["TarUName"] != null &&
                Session["TarUpwd"] != null &&
                !string.IsNullOrEmpty(Session["TarServerName"].ToString()) &&
                !string.IsNullOrEmpty(Session["TarUName"].ToString()) &&
                !string.IsNullOrEmpty(Session["SourUpwd"].ToString()) &&
                Session["SourServerName"] != null &&
                Session["SourUName"] != null &&
                Session["SourUpwd"] != null &&
                !string.IsNullOrEmpty(Session["SourServerName"].ToString()) &&
                !string.IsNullOrEmpty(Session["SourUName"].ToString()) &&
                !string.IsNullOrEmpty(Session["SourUpwd"].ToString()))
            {
                dc = new DBComparison(Session["TarServerName"].ToString(),
                    Session["TarUName"].ToString(),
                    Session["TarUpwd"].ToString(),
                    Session["SourServerName"].ToString(),
                    Session["SourUName"].ToString(),
                    Session["SourUpwd"].ToString());
            }
            sourDBS.Items.Clear();

            tarDBS.Items.Clear();
            foreach (string str in dc.getTargetDBS())
            {
                tarDBS.Items.Add(str);
            }
            foreach (string str in dc.getSourceDBS())
            {
                sourDBS.Items.Add(str);
            }
        }
Esempio n. 2
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Session["TarServerName"] != null &&
                Session["TarUName"] != null &&
                Session["TarUpwd"] != null &&
                !string.IsNullOrEmpty(Session["TarServerName"].ToString()) &&
                !string.IsNullOrEmpty(Session["TarUName"].ToString()) &&
                !string.IsNullOrEmpty(Session["SourUpwd"].ToString()) &&
                Session["SourServerName"] != null &&
                Session["SourUName"] != null &&
                Session["SourUpwd"] != null &&
                !string.IsNullOrEmpty(Session["SourServerName"].ToString()) &&
                !string.IsNullOrEmpty(Session["SourUName"].ToString()) &&
                !string.IsNullOrEmpty(Session["SourUpwd"].ToString()))
            {
                dc = new DBComparison(Session["TarServerName"].ToString(),
                                      Session["TarUName"].ToString(),
                                      Session["TarUpwd"].ToString(),
                                      Session["SourServerName"].ToString(),
                                      Session["SourUName"].ToString(),
                                      Session["SourUpwd"].ToString());
            }
            sourDBS.Items.Clear();

            tarDBS.Items.Clear();
            foreach (string str in dc.getTargetDBS())
            {
                tarDBS.Items.Add(str);
            }
            foreach (string str in dc.getSourceDBS())
            {
                sourDBS.Items.Add(str);
            }
        }