public override void setObject(BResource res) { base.setObject(res); auto = true; numericUpDown1.Value = cs.height; auto = false; pictureBox1.Refresh(); }
public override void setObject(BResource res) { base.setObject(res); comboBox1.SelectedIndex = -1; comboBox1.Items.Clear(); for (int i = 0; i < scr.scriptCount; i++) comboBox1.Items.Add(i.ToString()); }
public override void setObject(BResource res) { base.setObject(res); comboBox1.SelectedIndex = -1; comboBox1.Items.Clear(); comboBox2.SelectedIndex=-1; for (int i = 0; i < txt.blockCount; i++) comboBox1.Items.Add(i.ToString()); textBox1.Text = ""; }
public override void setObject(BResource res) { base.setObject(res); comboBox1.SelectedIndex = -1; comboBox1.Items.Clear(); for (int i = 0; i < scr.scriptCount; i++) { comboBox1.Items.Add(i.ToString()); } }
public override void setObject(BResource res) { base.setObject(res); comboBox1.SelectedIndex = -1; comboBox1.Items.Clear(); comboBox2.SelectedIndex = -1; for (int i = 0; i < txt.blockCount; i++) { comboBox1.Items.Add(i.ToString()); } textBox1.Text = ""; }
public override void setObject(BResource res) { base.setObject(res); button2.BackColor = seq.bgColor; timer1.Enabled = false; setPaletteCombo(comboBox1, seq.palette); label2.Text = String.Format("rep:{0:d} screens:{1:d}", seq.frameCnt, seq.screenCnt); numericUpDown1.Value = 50; timer1.Interval = 500; rbmp = seq.makeBitmap(seq.bgColor, getSelectedPalette(comboBox1)); frm = 0; makeBitmap(true); }
public override void setObject(BResource res) { base.setObject(res); snd = null;spc = null;mus = null; if (res.GetType().Name == "BSound") { snd = res as BSound; label1.Text = "PCM 11025 8bit mono : " + snd.getWave().length_s() + " sec"; } if (res.GetType().Name == "BMusic") mus = res as BMusic; if (res.GetType().Name == "BSpeech") { spc = res as BSpeech; label1.Text = "PCM 11025 8bit mono : " + spc.getWave().length_s()+" sec"; } }
public override void setObject(BResource res) { base.setObject(res); snd = null; spc = null; mus = null; if (res.GetType().Name == "BSound") { snd = res as BSound; label1.Text = "PCM 11025 8bit mono : " + snd.getWave().length_s() + " sec"; } if (res.GetType().Name == "BMusic") { mus = res as BMusic; } if (res.GetType().Name == "BSpeech") { spc = res as BSpeech; label1.Text = "PCM 11025 8bit mono : " + spc.getWave().length_s() + " sec"; } }
public override void setObject(BResource res) { base.setObject(res); auto = true; int w = img.width; int h = img.height; /* if (img.imgMode != 0) { w *= 16; h *= 8; } * */ numericUpDown1.Value = w; numericUpDown2.Value = h; checkBox1.Checked = (img.imgMode&1) != 0; checkBox2.Checked = (img.imgMode & 2) != 0; setPaletteCombo(comboBox1, img.palette); auto = false; repaint(); }
public override void setObject(BResource res) { base.setObject(res); auto = true; int w = img.width; int h = img.height; /* * if (img.imgMode != 0) * { * w *= 16; * h *= 8; * } * */ numericUpDown1.Value = w; numericUpDown2.Value = h; checkBox1.Checked = (img.imgMode & 1) != 0; checkBox2.Checked = (img.imgMode & 2) != 0; setPaletteCombo(comboBox1, img.palette); auto = false; repaint(); }
public override void setObject(BResource res) { bmp = null; numericUpDown1.Value = 50; timer1.Enabled = false; timer1.Interval = 500; curspr = 0; base.setObject(res); try { sprs = spr.header.n_sprites; setPaletteCombo(comboBox1, spr.palette); label1.Text = string.Format("{0:d} sprites {1:d}x{2:d}", spr.header.n_sprites, spr.header.width, spr.header.height); pictureBox1.Width = spr.header.width; pictureBox1.Height = spr.header.height; bmp = new Bitmap(spr.header.width, spr.header.height); } catch (Exception ex) { MainForm.clearResource(ex); } drawSprite(); }
public virtual void setObject(BResource res) { resource = res; }
public void RefreshMainValues() { objPrincipalCompany = null; var vPrincipalCompany = BPrincipalCompany.Get(); if (vPrincipalCompany != null) { objPrincipalCompany = vPrincipalCompany; RefreshStates(); RefreshModes(); txtRFC.Text = vPrincipalCompany.prco_rfc__nvarchar; txtCompany.Text = vPrincipalCompany.prco_name__nvarchar; txtAddress.Text = vPrincipalCompany.prco_address__nvarchar; txtPhone.Text = vPrincipalCompany.prco_phone__nvarchar; txtEmail.Text = vPrincipalCompany.prco_email__nvarchar; txtFacebook.Text = vPrincipalCompany.prco_facebook__nvarchar; if (vPrincipalCompany.city_uuid__uniqueidentifier != null) { var vCity = BCity.FindByUUID(vPrincipalCompany.city_uuid__uniqueidentifier.Value); cboState.Text = BState.FindByUUID(vCity.stat_uuid__uniqueidentifier).stat_name__nvarchar; cboCity.Text = vCity.city_name__nvarchar; RefreshCities(); } pcbLogo.Image = vPrincipalCompany.reso_uuid_logo__uniqueidentifier != null?Tools.ConvertirByteAImagen(BResource.FindByUUID(vPrincipalCompany.reso_uuid_logo__uniqueidentifier.Value).reso_value__varbinary) : null; cboMode.SelectedIndex = vPrincipalCompany.prco_developmentmode__bit ? 0 : 1; nudHoursToBackup.Value = objPrincipalCompany.prco_hoursbetweenbackups__int; nudDaysToDelete.Value = objPrincipalCompany.prco_daysdeletbackups__int; } }
private void btnCancel_Click(object sender, EventArgs e) { BPrincipalCompany.EnableToEdit(objPrincipalCompany.prco_uuid__uniqueidentifier); objPrincipalCompany = BPrincipalCompany.FindByUUID(objPrincipalCompany.prco_uuid__uniqueidentifier); txtRFC.Enabled = false; txtCompany.Enabled = false; txtAddress.Enabled = false; txtPhone.Enabled = false; txtEmail.Enabled = false; txtFacebook.Enabled = false; cboState.Enabled = false; cboCity.Enabled = false; pcbLogo.Enabled = false; cboMode.Enabled = false; nudHoursToBackup.Enabled = false; nudHoursToBackup.Enabled = false; txtRFC.Text = objPrincipalCompany.prco_rfc__nvarchar; txtCompany.Text = objPrincipalCompany.prco_name__nvarchar; txtAddress.Text = objPrincipalCompany.prco_address__nvarchar; txtPhone.Text = objPrincipalCompany.prco_phone__nvarchar; txtEmail.Text = objPrincipalCompany.prco_email__nvarchar; txtFacebook.Text = objPrincipalCompany.prco_facebook__nvarchar; cboState.Items.Clear(); cboCity.Items.Clear(); RefreshStates(); if (objPrincipalCompany.city_uuid__uniqueidentifier != null) { var vCity = BCity.FindByUUID(objPrincipalCompany.city_uuid__uniqueidentifier.Value); cboState.Text = BState.FindByUUID(vCity.stat_uuid__uniqueidentifier).stat_name__nvarchar; cboCity.Text = vCity.city_name__nvarchar; RefreshCities(); } pcbLogo.Image = objPrincipalCompany.reso_uuid_logo__uniqueidentifier != null?Tools.ConvertirByteAImagen(BResource.FindByUUID(objPrincipalCompany.reso_uuid_logo__uniqueidentifier.Value).reso_value__varbinary) : null; cboMode.SelectedIndex = objPrincipalCompany.prco_developmentmode__bit == true ? 0 : 1; nudHoursToBackup.Value = objPrincipalCompany.prco_hoursbetweenbackups__int; nudDaysToDelete.Value = objPrincipalCompany.prco_daysdeletbackups__int; btnAccept.Visible = btnCancel.Visible = false; btnEdit.Visible = true; btnClose.Enabled = true; btnEdit.Focus(); byAction = 0; }
public override void setObject(BResource res) { base.setObject(res); textBox1.Text = pal.name; pictureBox1.Refresh(); }
private bool RefreshMainValues() { if (cboType.SelectedIndex > -1) { try { var vPrincipalCompany = BPrincipalCompany.Get(); if (cboType.SelectedIndex == 0) { var vUsers = BUser.GetAllUsers(); List <Report_Users_001> objListReport = new List <Report_Users_001>(); if (vUsers != null) { for (int inCont = 0; inCont < vUsers.Count; inCont++) { string stCreatedBy, stModifiedBy; stCreatedBy = stModifiedBy = ""; var vUserBranches = BUser.GetAllBranches(vUsers[inCont].user_uuid__uniqueidentifier); if (vUserBranches != null && vUserBranches.Count > 1) { var vUser = BUser.FindByUUID(vUserBranches[0].user_uuid__uniqueidentifier.Value); stCreatedBy = Tools.Decrypt(vUser.user_firstname__nvarchar) + " " + Tools.Decrypt(vUser.user_lastname__nvarchar); vUser = BUser.FindByUUID(vUserBranches[vUserBranches.Count - 1].user_uuid__uniqueidentifier.Value); stModifiedBy = Tools.Decrypt(vUser.user_firstname__nvarchar) + " " + Tools.Decrypt(vUser.user_lastname__nvarchar); } else { stCreatedBy = Tools.Decrypt(vUsers[inCont].user_firstname__nvarchar) + " " + Tools.Decrypt(vUsers[inCont].user_lastname__nvarchar); } objListReport.Add(new Report_Users_001() { Number = Convert.ToString(inCont + 1), Username = vUsers[inCont].user_username__nvarchar, Email = vUsers[inCont].user_email__nvarchar, Cellphone = vUsers[inCont].user_cellphone__nvarchar, FirstName = Tools.Decrypt(vUsers[inCont].user_firstname__nvarchar), LastName = Tools.Decrypt(vUsers[inCont].user_lastname__nvarchar), RoleAccess = vUsers[inCont].user_roleaccess__tinyint == 1 ? "Administrator" : "<>", CreatedBy = stCreatedBy, LastModificationBy = stModifiedBy }); } } /////////////////////////////////////////////////////////////////////////////// rpvReport.LocalReport.ReportEmbeddedResource = "General_Desktop_Application.Reports.Report_Users_001.rdlc"; // We clean DataSource of report. rpvReport.LocalReport.DataSources.Clear(); // // We establish the parameters that we'll send them to report. // string stPUser = Tools.Decrypt(ObjForm_004.ObjUser.user_firstname__nvarchar) + " " + Tools.Decrypt(ObjForm_004.ObjUser.user_lastname__nvarchar); string stPCompany = vPrincipalCompany.prco_name__nvarchar; string stPAddress = vPrincipalCompany.prco_address__nvarchar != null ? vPrincipalCompany.prco_address__nvarchar : ""; ReportParameter[] objReportParameter = { new ReportParameter("pReportName", "User Report"), new ReportParameter("pLogo", vPrincipalCompany.reso_uuid_logo__uniqueidentifier != null ? Convert.ToBase64String(BResource.FindByUUID(vPrincipalCompany.reso_uuid_logo__uniqueidentifier.Value).reso_value__varbinary) : null), new ReportParameter("pDate", DateTime.Now.ToShortDateString() + " " + DateTime.Now.ToShortTimeString()), new ReportParameter("pCompany", stPCompany.Length > 20 ? stPCompany.Substring(0, 20) : stPCompany), new ReportParameter("pRFC", vPrincipalCompany.prco_rfc__nvarchar != null ? vPrincipalCompany.prco_rfc__nvarchar :null), new ReportParameter("pUser", stPUser.Length > 20 ? stPUser.Substring(0, 20) : stPUser), new ReportParameter("pAddress", stPAddress.Length > 20 ? stPAddress.Substring(0, 20):stPAddress) }; // We send the list with parameters. rpvReport.LocalReport.SetParameters(objReportParameter); // // We establish the list as report's Datasource. // rpvReport.LocalReport.DataSources.Add(new ReportDataSource("dsReport_User_001", objListReport)); // We adjust the report's visualization mode. rpvReport.SetDisplayMode(DisplayMode.PrintLayout); rpvReport.ZoomMode = ZoomMode.Percent; rpvReport.ZoomPercent = 100; // // We do a refresh to reportViewer. // rpvReport.RefreshReport(); } } catch { MessageBox.Show(Preferences.GlobalErrorOperation, Preferences.TitleSoftware, MessageBoxButtons.OK, MessageBoxIcon.Information); return(false); } } return(true); }