예제 #1
0
        public cFeedBackMessage Run()
        {
            ContextMenuStrip GridViewContextMenu = new ContextMenuStrip();

            ToolStripMenuItem ToolStripMenuItem_DisplayAS = new ToolStripMenuItem("Display as...");

            ToolStripMenuItem ToolStripMenuItem_DisplayHeatMap = new ToolStripMenuItem("Heat Map");
            ToolStripMenuItem_DisplayAS.DropDownItems.Add(ToolStripMenuItem_DisplayHeatMap);
            ToolStripMenuItem_DisplayHeatMap.Click += new System.EventHandler(this.DisplayHeatMap);

            ToolStripMenuItem ToolStripMenuItem_DisplayElevationMap = new ToolStripMenuItem("Elevation Map");
            ToolStripMenuItem_DisplayAS.DropDownItems.Add(ToolStripMenuItem_DisplayElevationMap);
            ToolStripMenuItem_DisplayElevationMap.Click += new System.EventHandler(this.DisplayElevationMap);

            ToolStripMenuItem ToolStripMenuItem_Display2DScatterGraph = new ToolStripMenuItem("2D Scatter Graph");
            ToolStripMenuItem_DisplayAS.DropDownItems.Add(ToolStripMenuItem_Display2DScatterGraph);
            ToolStripMenuItem_Display2DScatterGraph.Click += new System.EventHandler(this.ToolStripMenuItem_Display2DScatterGraph);

            ToolStripMenuItem ToolStripMenuItem_DisplayAsImage = new ToolStripMenuItem("Image");
            ToolStripMenuItem_DisplayAS.DropDownItems.Add(ToolStripMenuItem_DisplayAsImage);
            ToolStripMenuItem_DisplayAsImage.Click += new System.EventHandler(this.ToolStripMenuItem_DisplayAsImage);

            ToolStripMenuItem_DisplayAS.DropDownItems.Add(new ToolStripSeparator());

            ToolStripMenuItem ToolStripMenuItem_SaveAsCSV = new ToolStripMenuItem("CSV file");
            ToolStripMenuItem_DisplayAS.DropDownItems.Add(ToolStripMenuItem_SaveAsCSV);
            ToolStripMenuItem_SaveAsCSV.Click += new System.EventHandler(this.ToolStripMenuItem_SaveAsCSV);

            ToolStripMenuItem ToolStripMenuItem_ToClipBoard = new ToolStripMenuItem("CSV to ClipBoard");
            ToolStripMenuItem_DisplayAS.DropDownItems.Add(ToolStripMenuItem_ToClipBoard);
            ToolStripMenuItem_ToClipBoard.Click += new System.EventHandler(this.ToolStripMenuItem_ToClipBoard);

            GridViewContextMenu.Items.Add(ToolStripMenuItem_DisplayAS);

            CurrentPanel.Title = this.Title;

            CurrentPanel.Width = 0;
            CurrentPanel.Height = 0;

            RichText.Width = CurrentPanel.Width;
            RichText.Height = CurrentPanel.Height;

            this.CurrentPanel.Anchor = (System.Windows.Forms.AnchorStyles)(System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom
            | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right);

            RichText.Anchor = (System.Windows.Forms.AnchorStyles)(System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom
            | System.Windows.Forms.AnchorStyles.Left| System.Windows.Forms.AnchorStyles.Right);

            cTableToClipBoard TTC = new cTableToClipBoard();
            //TTC.IsRTFFormat = true;
            TTC.SetInputData(this.Input);
            TTC.Run();

            RichText.AppendText(Clipboard.GetText());
            //RichText.Rtf = Clipboard.GetText();

            CurrentPanel.Controls.Add(RichText);

            return base.FeedBackMessage;
        }
예제 #2
0
 private void ToolStripMenuItem_ToClipBoard(object sender, EventArgs e)
 {
     cTableToClipBoard TCLB = new cTableToClipBoard();
     TCLB.SetInputData(this.Input);
     TCLB.Run();
 }