private void bEmbedded_Click(object sender, System.EventArgs e) { DialogEmbeddedImages dlgEI = new DialogEmbeddedImages(this._Draw); dlgEI.StartPosition = FormStartPosition.CenterParent; try { DialogResult dr = dlgEI.ShowDialog(); if (dr != DialogResult.OK) { return; } } finally { dlgEI.Dispose(); } // Populate the EmbeddedImage names cbValueEmbedded.Items.Clear(); cbValueEmbedded.Items.AddRange(_Draw.ReportNames.EmbeddedImageNames); }
private void bEmbedded_Click(object sender, System.EventArgs e) { DialogEmbeddedImages dlgEI = new DialogEmbeddedImages(this._Draw); dlgEI.StartPosition = FormStartPosition.CenterParent; try { DialogResult dr = dlgEI.ShowDialog(); if (dr != DialogResult.OK) return; // Populate the EmbeddedImage names cbValueEmbedded.Items.Clear(); cbValueEmbedded.Items.AddRange(_Draw.ReportNames.EmbeddedImageNames); } finally { dlgEI.Dispose(); } }
private void menuEmbeddedImages_Click(object sender, System.EventArgs e) { MDIChild mc = this.ActiveMdiChild as MDIChild; if (mc == null) return; mc.Editor.StartUndoGroup("Embedded Images Dialog"); using (DialogEmbeddedImages dlgEI = new DialogEmbeddedImages(mc.DrawCtl)) { dlgEI.StartPosition = FormStartPosition.CenterParent; DialogResult dr = dlgEI.ShowDialog(); mc.Editor.EndUndoGroup(dr == DialogResult.OK); if (dr == DialogResult.OK) mc.Modified = true; } }