コード例 #1
0
        private void dataSourcesToolStripMenuItem1_Click(object sender, System.EventArgs e)
        {
            MDIChild mc = this.ActiveMdiChild as MDIChild;
            if (mc == null)
                return;

            mc.Editor.StartUndoGroup(Strings.RdlDesigner_Undo_DataSourcesDialog);
            using (DialogDataSources dlgDS = new DialogDataSources(mc.SourceFile, mc.DrawCtl))
            {
                dlgDS.StartPosition = FormStartPosition.CenterParent;
                DialogResult dr = dlgDS.ShowDialog();
                mc.Editor.EndUndoGroup(dr == DialogResult.OK);
                if (dr == DialogResult.OK)
                    mc.Modified = true;
            }
        }
コード例 #2
0
		private void menuDataSources_Click(object sender, System.EventArgs e)
		{
			MDIChild mc = this.ActiveMdiChild as MDIChild;
			if (mc == null)
				return;

			mc.Editor.StartUndoGroup("DataSources Dialog");
			DialogDataSources dlgDS = new DialogDataSources(mc.DrawCtl);
			dlgDS.StartPosition = FormStartPosition.CenterParent;
			DialogResult dr = dlgDS.ShowDialog();
			mc.Editor.EndUndoGroup(dr == DialogResult.OK);
			if (dr == DialogResult.OK)
				mc.Modified = true;
		}