protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { if (Request.QueryString["sid"] != null) { //---------------------------------------------------------------------------------------------------------- string sid = BZ_Common.BZ_Decrypted(Request.QueryString["sid"].ToString()); //kdQMwcj0lE8= "5"; // ViewState["sid"] = sid; //----------------------------------------------------------------------------------------------------------- Int64 Count = 0; DataTable ds = MyCommonfile.selectBZ(" Select * From Sync_Need_Logs Order By LogId "); for (int iicouts = 0; iicouts < ds.Rows.Count; iicouts++) { Count++; DataTable DTServerID = MyCommonfile.selectBZ(" SELECT DISTINCT dbo.ServerMasterTbl.Id FROM dbo.CompanyMaster INNER JOIN dbo.PricePlanMaster ON dbo.PricePlanMaster.PricePlanId = dbo.CompanyMaster.PricePlanId INNER JOIN dbo.PortalMasterTbl ON dbo.PricePlanMaster.PortalMasterId1 = dbo.PortalMasterTbl.Id INNER JOIN dbo.VersionInfoMaster ON dbo.PricePlanMaster.VersionInfoMasterId = dbo.VersionInfoMaster.VersionInfoId INNER JOIN dbo.ProductMaster ON dbo.VersionInfoMaster.ProductId = dbo.ProductMaster.ProductId INNER JOIN dbo.ClientMaster ON dbo.ProductMaster.ClientMasterId = dbo.ClientMaster.ClientMasterId INNER JOIN dbo.ServerMasterTbl ON dbo.CompanyMaster.ServerId = dbo.ServerMasterTbl.Id Where dbo.ServerMasterTbl.Status=1 and dbo.CompanyMaster.Active=1 "); for (int iicout = 0; iicout < DTServerID.Rows.Count; iicout++) { Insert_Sync_Need_Logs_AtServer_AddDelUpdtSelect(ds.Rows[iicouts]["LogId"].ToString(), ds.Rows[iicouts]["RecordID"].ToString(), ds.Rows[iicouts]["ACTION"].ToString(), ds.Rows[iicouts]["TableName"].ToString(), false, DTServerID.Rows[iicout]["Id"].ToString()); } DELETE__Sync_Need_Logs__AddDelUpdtSelect(ds.Rows[iicouts]["LogId"].ToString()); } lblmsg.Text = Convert.ToString(Count) + " total record updated at Sync_Need_Logs_AtServer"; TransferAtJbTable(ViewState["sid"].ToString()); } } }
protected void Page_Load(object sender, EventArgs e) { // Statik_FullTable(); string sidd = BZ_Common.BZ_Encrypted("5"); if (!IsPostBack) { if (Request.QueryString["sid"] != null && Request.QueryString["tblid"] == null) { string sid = BZ_Common.BZ_Decrypted(Request.QueryString["sid"].ToString()); //kdQMwcj0lE8= "5"; // ViewState["sid"] = sid; //---------------------------------------------------------------------------------------------------------- //----------------------------------------------------------------------------------------------------------- if (!IsPostBack) { btnsync_Click(sender, e); } DataTable dtfindtab = MyCommonfile.selectBZ(@" SELECT Count(dbo.Satelite_Server_Sync_Log_Deatils.ID) as TotalCount From dbo.Satellite_Server_Sync_Job_Details INNER JOIN dbo.ClientProductTableMaster INNER JOIN dbo.SatelliteSyncronisationrequiringTablesMaster ON dbo.SatelliteSyncronisationrequiringTablesMaster.TableID = dbo.ClientProductTableMaster.Id ON dbo.Satellite_Server_Sync_Job_Details.TableID = dbo.SatelliteSyncronisationrequiringTablesMaster.TableID AND dbo.Satellite_Server_Sync_Job_Details.TableID = dbo.ClientProductTableMaster.Id INNER JOIN dbo.Satelitte_Server_Sync_Job_Master ON dbo.Satellite_Server_Sync_Job_Details.Satelitte_Server_Sync_Job_Master_ID = dbo.Satelitte_Server_Sync_Job_Master.Id INNER JOIN dbo.ServerMasterTbl ON dbo.Satelitte_Server_Sync_Job_Master.SatelliteServerID = dbo.ServerMasterTbl.Id INNER JOIN dbo.Satelite_Server_Sync_Log_Deatils ON dbo.Satellite_Server_Sync_Job_Details.ID = dbo.Satelite_Server_Sync_Log_Deatils.Satellite_Server_Sync_Job_Details_ID INNER JOIN dbo.SyncActionMaster ON dbo.Satelite_Server_Sync_Log_Deatils.TypeOfOperationDone = dbo.SyncActionMaster.ID Where dbo.Satellite_Server_Sync_Job_Details.SyncedStatus=0 and ServerMasterTbl.Id='" + ViewState["sid"] + "' ");// and dbo.Satelitte_Server_Sync_Job_Master.Id='" + ViewState["JobID"] + "' and lblportmsg.Text = "Please waite for some moment we syncronice " + dtfindtab.Rows[0]["TotalCount"] + " record at server "; } else { } //Any 1 Table Full Data Transfer if (Request.QueryString["sid"] != null && Request.QueryString["tblid"] != null) { string sid = BZ_Common.BZ_Decrypted(Request.QueryString["sid"].ToString().Replace(" ", "+")); string tblid = BZ_Common.BZ_Decrypted(Request.QueryString["tblid"].ToString().Replace(" ", "+")); ViewState["sid"] = sid; ViewState["tblid"] = tblid; FullTableSync(); } //All Table All Data Transfer if (Request.QueryString["sid"] != null && Request.QueryString["alltable"] != null) { string sid = BZ_Common.BZ_Decrypted(Request.QueryString["sid"].ToString().Replace(" ", "+")); ViewState["sid"] = sid; // string tblid = BZ_Common.BZ_Decrypted(Request.QueryString["tblid"].ToString().Replace(" ", "+")); DataTable dts1 = MyCommonfile.selectBZ(" SELECT dbo.SatelliteSyncronisationrequiringTablesMaster.* FROM dbo.ClientProductTableMaster INNER JOIN dbo.SatelliteSyncronisationrequiringTablesMaster ON dbo.SatelliteSyncronisationrequiringTablesMaster.TableID = dbo.ClientProductTableMaster.Id WHERE (dbo.SatelliteSyncronisationrequiringTablesMaster.Status = '1' and ClientProductTableMaster.Active=1) "); for (int k = 0; k < dts1.Rows.Count; k++) { ViewState["tblid"] = dts1.Rows[k]["TableID"].ToString(); FullTableSync(); } } } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { Timer1.Enabled = false; img_loading.Visible = false; //--Part1------------------------Add Sync_Need_Logs_AtServer Table-------------------------------------------------------------------------------- if (Request.QueryString["sid"] != null && Request.QueryString["addserjob"] == "1") { string sid = Request.QueryString["sid"].Replace(" ", "+"); //kdQMwcj0lE8= "5"; // sid = BZ_Common.BZ_Decrypted(sid); ViewState["sid"] = sid; DataTable ds = MyCommonfile.selectBZ(" Select Count(Logid) as id From Sync_Need_Logs "); if (Convert.ToInt32(ds.Rows[0]["id"].ToString()) > 0) { lbl_Hmsg.Text = "";// "We finded total " + ds.Rows[0]["id"].ToString() + " no of changes done at client database right now we need to transfer record at settellite server level "; Timer1.Enabled = true; img_loading.Visible = true; } else { lbl_Msg.Text = "No any record available for syncronice"; } } //--------------------------------------------------------------------------------------------------------------------------------------- //--Part2------------------------Add Job1-Job2-Job3 Table-------------------------------------------------------------------------------- if (Request.QueryString["sid"] != null && Request.QueryString["addjob123"] == "1") { string sid = Request.QueryString["sid"].Replace(" ", "+"); //kdQMwcj0lE8= "5"; // sid = BZ_Common.BZ_Decrypted(sid); ViewState["sid"] = sid; DataTable ds1 = MyCommonfile.selectBZ(" Select Count(id) as id From Sync_Need_Logs_AtServer where sid='" + ViewState["sid"].ToString() + "' "); if (Convert.ToInt32(ds1.Rows[0]["id"].ToString()) > 0) { lbl_Hmsg.Text = "";// "We finded total " + ds1.Rows[0]["id"].ToString() + " record that need to be transfer on sattellite server right now we create one job for transfer all record at settellite server"; TransferAtJob1Job2(sid); Timer1.Enabled = true; img_loading.Visible = true; } else { lbl_Msg.Text = "No any record available for create job for syncronice "; } } } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { Timer1.Enabled = false; img_loading.Visible = false; if (Request.QueryString["sid"] != null && Request.QueryString["addserjob"] == "1") { //---------------------------------------------------------------------------------------------------------- string sid = Request.QueryString["sid"].Replace(" ", "+"); //kdQMwcj0lE8= "5"; // sid = BZ_Common.BZ_Decrypted(sid); ViewState["sid"] = sid; DataTable ds = MyCommonfile.selectBZ(" Select * From Sync_Need_Logs Order By LogId "); if (ds.Rows.Count > 0) { Timer1.Enabled = true; img_loading.Visible = true; } else { lbl_Msg.Text = "No any record available for syncronice"; } //----------------------------------------------------------------------------------------------------------- } if (Request.QueryString["sid"] != null && Request.QueryString["addjob123"] == "1") { string sid = Request.QueryString["sid"].Replace(" ", "+"); //kdQMwcj0lE8= "5"; // sid = BZ_Common.BZ_Decrypted(sid); ViewState["sid"] = sid; DataTable ds1 = MyCommonfile.selectBZ(" Select * From Sync_Need_Logs_AtServer where sid='" + ViewState["sid"].ToString() + "' Order By LogId "); if (ds1.Rows.Count > 0) { TransferAtJob1Job2(sid); Timer1.Enabled = true; img_loading.Visible = true; } else { lbl_Msg.Text = "No any record available for create job for syncronice "; } } } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { Timer1.Enabled = false; img_loading.Visible = false; //--Part3------------------------Add Job3 Table To Server Database-------------------------------------------------------------------------------- if (Request.QueryString["sid"] != null && Request.QueryString["Transfer"] == "1") { string sid = Request.QueryString["sid"].Replace(" ", "+"); //kdQMwcj0lE8= "5"; // sid = BZ_Common.BZ_Decrypted(sid); ViewState["sid"] = sid; Timer1.Enabled = true; img_loading.Visible = true; Count_Job3_Record(ViewState["sid"].ToString()); } } }
protected void Page_Load(object sender, EventArgs e) { string ss = BZ_Common.BZ_Decrypted("d2fu/WL5XmM="); string ssdd = BZ_Common.BZ_Decrypted("member"); string ssddfdf = BZ_Common.BZ_Encrypted("member"); //ABC Key Insert At Server DB if (Request.QueryString["comid"] != null && Request.QueryString["ABCenckey"] != null && Request.QueryString["returl"] != null) { //string hh = BZ_Common.BZ_Decrypted(Request.QueryString["comid"].ToString().Replace(" ", "+")); string companyid = BZ_Common.BZ_Decrypted(Request.QueryString["comid"].ToString().Replace(" ", "+")); DataTable DtServid = MyCommonfile.selectBZ(" Select ServerMasterTbl.Busiwizsatellitesiteurl,CompanyMaster.CompanyLoginId,ServerMasterTbl.Id FROM dbo.ServerMasterTbl INNER JOIN dbo.CompanyMaster ON dbo.ServerMasterTbl.Id = dbo.CompanyMaster.ServerId Where CompanyMaster.CompanyLoginId='" + companyid + "' "); if (DtServid.Rows.Count > 0) { string Busiwizsatellitesiteurl = DtServid.Rows[0]["Busiwizsatellitesiteurl"].ToString(); string ServerId = DtServid.Rows[0]["Id"].ToString(); Boolean Comp__Actve__Status = CompanyWizard.Company_Active_Status(companyid); Boolean Comp__Licen__Active = CompanyWizard.Company_LicenseExpire_Status(companyid); Boolean Server__Active = ServerWizard.Server_Active_Status(companyid); if (Comp__Actve__Status == true && Comp__Licen__Active == true && Server__Active == true) { Boolean Insert_Today_Key = CompKeyIns.BtnABCKey(companyid, ServerId); if (Insert_Today_Key == true) { string Z = ""; string D1 = ""; string D2 = ""; string D3 = ""; string D4 = ""; string D5 = ""; string E1 = ""; string E2 = ""; string E3 = ""; string E4 = ""; string E5 = ""; string F1 = ""; string F2 = ""; string F3 = ""; string F4 = ""; string F5 = ""; DataTable Dt = MyCommonfile.selectBZ(" Select TOP(15)* From CompanyABCDetail Where CompanyLoginId='" + companyid + "' Order By Id Desc "); foreach (DataRow drmaxdb in Dt.Rows) { Z += drmaxdb["Z"].ToString() + ","; D1 += drmaxdb["D1"].ToString() + ","; D2 += drmaxdb["D2"].ToString() + ","; D3 += drmaxdb["D3"].ToString() + ","; D4 += drmaxdb["D4"].ToString() + ","; D5 += drmaxdb["D5"].ToString() + ","; E1 += drmaxdb["E1"].ToString() + ","; E2 += drmaxdb["E2"].ToString() + ","; E3 += drmaxdb["E3"].ToString() + ","; E4 += drmaxdb["E4"].ToString() + ","; E5 += drmaxdb["E5"].ToString() + ","; F1 += drmaxdb["F1"].ToString() + ","; F2 += drmaxdb["F2"].ToString() + ","; F3 += drmaxdb["F3"].ToString() + ","; F4 += drmaxdb["F4"].ToString() + ","; F5 += drmaxdb["F5"].ToString() + ","; } if (Dt.Rows.Count > 0) { Z = Z.Remove(Z.Length - 1); D1 = D1.Remove(D1.Length - 1); D2 = D2.Remove(D2.Length - 1); D3 = D3.Remove(D3.Length - 1); D4 = D4.Remove(D4.Length - 1); D5 = D5.Remove(D5.Length - 1); E1 = E1.Remove(E1.Length - 1); E2 = E2.Remove(E2.Length - 1); E3 = E3.Remove(E3.Length - 1); E4 = E4.Remove(E4.Length - 1); E5 = E5.Remove(E5.Length - 1); F1 = F1.Remove(F1.Length - 1); F2 = F2.Remove(F2.Length - 1); F3 = F3.Remove(F3.Length - 1); F4 = F4.Remove(F4.Length - 1); F5 = F5.Remove(F5.Length - 1); //Response.Redirect("http://" + Busiwizsatellitesiteurl + "/Satelliteservfunction.aspx?Compid=" + BZ_Common.BZ_Encrypted(companyid) + "&E1=" + BZ_Common.BZ_Encrypted(E1) + "&E2=" + BZ_Common.BZ_Encrypted(E2) + "&E3=" + BZ_Common.BZ_Encrypted(E3) + "&E4=" + BZ_Common.BZ_Encrypted(E4) + "&E5=" + BZ_Common.BZ_Encrypted(E5) + "&D1=" + BZ_Common.BZ_Encrypted(D1) + "&D2=" + BZ_Common.BZ_Encrypted(D2) + "&D3=" + BZ_Common.BZ_Encrypted(D3) + "&D4=" + BZ_Common.BZ_Encrypted(D4) + "&D5=" + BZ_Common.BZ_Encrypted(D5) + "&Z=" + BZ_Common.BZ_Encrypted(Z) + "&F1=" + BZ_Common.BZ_Encrypted(F1) + "&F2=" + BZ_Common.BZ_Encrypted(F2) + "&F3=" + BZ_Common.BZ_Encrypted(F3) + "&F4=" + BZ_Common.BZ_Encrypted(F4) + "&F5=" + BZ_Common.BZ_Encrypted(F5) + ""); Response.Redirect("http://" + Busiwizsatellitesiteurl + "/Satelliteservfunction.aspx?Compid=" + BZ_Common.BZ_Encrypted(companyid) + "&E1=" + E1 + "&E2=" + E2 + "&E3=" + E3 + "&E4=" + E4 + "&E5=" + E5 + "&D1=" + D1 + "&D2=" + D2 + "&D3=" + D3 + "&D4=" + D4 + "&D5=" + D5 + "&Z=" + Z + "&F1=" + F1 + "&F2=" + F2 + "&F3=" + F3 + "&F4=" + F4 + "&F5=" + F5 + "&returl=" + Request.QueryString["returl"] + ""); } lbl_msg.Text = "Successfully "; } else { lbl_msg.Text = "Some problem when we try to adding records in database "; } } else if (Comp__Actve__Status == false) { lbl_msg.Text = "Company not active "; } else if (Comp__Licen__Active == false) { lbl_msg.Text = "License Expired"; } else if (Server__Active == false) { lbl_msg.Text = "Server Inactive"; } } } }