//控件初始化 private void InitializeComponent() { this.icontainer_0 = new Container(); DataGridViewCellStyle style = new DataGridViewCellStyle(); this.contextMenuStrip1 = new ContextMenuStrip(this.icontainer_0); this.toolStripSeparator1 = new ToolStripSeparator(); this.menu_Add = new ToolStripMenuItem(); this.menu_Edit = new ToolStripMenuItem(); this.menu_Delete = new ToolStripMenuItem(); this.menu_Refresh = new ToolStripMenuItem(); this.toolStripSeparator2 = new ToolStripSeparator(); this.menu_Print = new ToolStripMenuItem(); this.dataGridView1 = new DataGridView(); this.panel1 = new Panel(); this.pager = new Pager(); this.PtgOfUaBU = new ToolStripMenuItem(); this.contextMenuStrip1.SuspendLayout(); ((ISupportInitialize) this.dataGridView1).BeginInit(); this.panel1.SuspendLayout(); base.SuspendLayout(); this.contextMenuStrip1.Items.AddRange(new ToolStripItem[] { this.toolStripSeparator1, this.menu_Add, this.menu_Edit, this.menu_Delete, this.menu_Refresh, this.toolStripSeparator2, this.menu_Print, this.PtgOfUaBU }); this.contextMenuStrip1.Name = "contextMenuStrip1"; this.contextMenuStrip1.Size = new Size(0x161, 170); this.toolStripSeparator1.Name = "toolStripSeparator1"; this.toolStripSeparator1.Size = new Size(0x15d, 6); this.menu_Add.Name = "menu_Add"; this.menu_Add.Size = new Size(0x160, 0x16); this.menu_Add.Text = "新建(&N)"; this.menu_Add.Click += new EventHandler(this.menu_Add_Click); this.menu_Edit.Name = "menu_Edit"; this.menu_Edit.Size = new Size(0x160, 0x16); this.menu_Edit.Text = "编辑选定项(&E)"; this.menu_Edit.Click += new EventHandler(this.menu_Edit_Click); this.menu_Delete.Name = "menu_Delete"; this.menu_Delete.Size = new Size(0x160, 0x16); this.menu_Delete.Text = "删除选定项(&D)"; this.menu_Delete.Click += new EventHandler(this.menu_Delete_Click); this.menu_Refresh.Name = "menu_Refresh"; this.menu_Refresh.Size = new Size(0x160, 0x16); this.menu_Refresh.Text = "刷新列表(&R)"; this.menu_Refresh.Click += new EventHandler(this.menu_Refresh_Click); this.toolStripSeparator2.Name = "toolStripSeparator2"; this.toolStripSeparator2.Size = new Size(0x15d, 6); this.menu_Print.Name = "menu_Print"; this.menu_Print.Size = new Size(0x160, 0x16); this.menu_Print.Text = "打印列表(&P)"; this.menu_Print.Click += new EventHandler(this.menu_Print_Click); this.dataGridView1.AllowUserToAddRows = false; this.dataGridView1.AllowUserToDeleteRows = false; this.dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; this.dataGridView1.ContextMenuStrip = this.contextMenuStrip1; this.dataGridView1.Dock = DockStyle.Fill; this.dataGridView1.Location = new Point(0, 0); this.dataGridView1.Name = "dataGridView1"; this.dataGridView1.ReadOnly = true; style.Padding = new Padding(0, 2, 0, 2); this.dataGridView1.RowsDefaultCellStyle = style; this.dataGridView1.RowTemplate.Height = 0x17; this.dataGridView1.SelectionMode = DataGridViewSelectionMode.FullRowSelect; this.dataGridView1.Size = new Size(640, 0xac); this.dataGridView1.TabIndex = 11; this.dataGridView1.RowEnter += new DataGridViewCellEventHandler(this.dataGridView1_RowEnter); this.dataGridView1.CellDoubleClick += new DataGridViewCellEventHandler(this.dataGridView1_CellDoubleClick); this.dataGridView1.RowLeave += new DataGridViewCellEventHandler(this.dataGridView1_RowLeave); this.dataGridView1.DataSourceChanged += new EventHandler(this.dataGridView1_DataSourceChanged); this.panel1.Controls.Add(this.pager); this.panel1.Dock = DockStyle.Bottom; this.panel1.Location = new Point(0, 0xac); this.panel1.Name = "panel1"; this.panel1.Size = new Size(640, 40); this.panel1.TabIndex = 9; this.pager.CurrentPageIndex = 1; this.pager.Cursor = Cursors.Hand; this.pager.Dock = DockStyle.Fill; this.pager.Location = new Point(0, 0); this.pager.Name = "pager"; this.pager.RecordCount = 0; this.pager.Size = new Size(640, 40); this.pager.TabIndex = 0; this.PtgOfUaBU.ForeColor = Color.Red; this.PtgOfUaBU.Name = "menu_Buy"; this.PtgOfUaBU.Size = new Size(0x160, 0x16); this.PtgOfUaBU.Text = "未注册版本,购买请访问http://www.iqidi.com(&G)"; this.PtgOfUaBU.Click += new EventHandler(this.nvOwJvOxl); base.AutoScaleMode = AutoScaleMode.Inherit; base.Controls.Add(this.dataGridView1); base.Controls.Add(this.panel1); this.MinimumSize = new Size(540, 0); base.Name = "WinGridViewPager"; base.Size = new Size(640, 0xd4); this.contextMenuStrip1.ResumeLayout(false); ((ISupportInitialize) this.dataGridView1).EndInit(); this.panel1.ResumeLayout(false); base.ResumeLayout(false); }
private void InitializeComponent() { this.icontainer_0 = new Container(); this.btnExport = new Button(); this.contextMenuStrip1 = new ContextMenuStrip(this.icontainer_0); this.toolStripSeparator1 = new ToolStripSeparator(); this.menu_Delete = new ToolStripMenuItem(); this.menu_Refresh = new ToolStripMenuItem(); this.menu_Print = new ToolStripMenuItem(); this.toolStripSeparator2 = new ToolStripSeparator(); this.btnExportCurrent = new Button(); this.listView1 = new ListView(); this.pager = new Pager(); this.contextMenuStrip1.SuspendLayout(); base.SuspendLayout(); this.btnExport.Anchor = AnchorStyles.Right | AnchorStyles.Bottom; this.btnExport.Location = new Point(0x1cf, 0xb9); this.btnExport.Name = "btnExport"; this.btnExport.Size = new Size(0x4a, 0x17); this.btnExport.TabIndex = 5; this.btnExport.Text = "导出全部页"; this.btnExport.UseVisualStyleBackColor = true; this.btnExport.Click += new EventHandler(this.btnExport_Click); this.contextMenuStrip1.Items.AddRange(new ToolStripItem[] { this.toolStripSeparator1, this.menu_Delete, this.menu_Refresh, this.menu_Print, this.toolStripSeparator2 }); this.contextMenuStrip1.Name = "contextMenuStrip1"; this.contextMenuStrip1.Size = new Size(0x9a, 0x52); this.toolStripSeparator1.Name = "toolStripSeparator1"; this.toolStripSeparator1.Size = new Size(150, 6); this.menu_Delete.Name = "menu_Delete"; this.menu_Delete.Size = new Size(0x99, 0x16); this.menu_Delete.Text = "删除选定项(&D)"; this.menu_Delete.Click += new EventHandler(this.menu_Delete_Click); this.menu_Refresh.Name = "menu_Refresh"; this.menu_Refresh.Size = new Size(0x99, 0x16); this.menu_Refresh.Text = "刷新列表(&R)"; this.menu_Refresh.Click += new EventHandler(this.menu_Refresh_Click); this.menu_Print.Name = "menu_Print"; this.menu_Print.Size = new Size(0x99, 0x16); this.menu_Print.Text = "打印列表(&P)"; this.menu_Print.Click += new EventHandler(this.menu_Print_Click); this.toolStripSeparator2.Name = "toolStripSeparator2"; this.toolStripSeparator2.Size = new Size(150, 6); this.btnExportCurrent.Anchor = AnchorStyles.Right | AnchorStyles.Bottom; this.btnExportCurrent.Location = new Point(0x17f, 0xb9); this.btnExportCurrent.Name = "btnExportCurrent"; this.btnExportCurrent.Size = new Size(0x4a, 0x17); this.btnExportCurrent.TabIndex = 5; this.btnExportCurrent.Text = "导出当前页"; this.btnExportCurrent.UseVisualStyleBackColor = true; this.btnExportCurrent.Click += new EventHandler(this.btnExportCurrent_Click); this.listView1.Anchor = AnchorStyles.Right | AnchorStyles.Left | AnchorStyles.Bottom | AnchorStyles.Top; this.listView1.ContextMenuStrip = this.contextMenuStrip1; this.listView1.Font = new Font("宋体", 12f, FontStyle.Regular, GraphicsUnit.Point, 0x86); this.listView1.FullRowSelect = true; this.listView1.GridLines = true; this.listView1.HeaderStyle = ColumnHeaderStyle.Nonclickable; this.listView1.HideSelection = false; this.listView1.Location = new Point(0, 0); this.listView1.Name = "listView1"; this.listView1.Size = new Size(540, 0xb3); this.listView1.TabIndex = 6; this.listView1.UseCompatibleStateImageBehavior = false; this.listView1.View = View.Details; this.pager.Anchor = AnchorStyles.Right | AnchorStyles.Bottom; this.pager.CurrentPageIndex = 1; this.pager.Cursor = Cursors.Hand; this.pager.Location = new Point(-49, 0xb9); this.pager.Name = "pager"; this.pager.PageSize = 20; this.pager.RecordCount = 0; this.pager.Size = new Size(0x1b2, 0x18); this.pager.TabIndex = 4; base.AutoScaleMode = AutoScaleMode.Inherit; base.Controls.Add(this.listView1); base.Controls.Add(this.btnExportCurrent); base.Controls.Add(this.btnExport); base.Controls.Add(this.pager); this.MinimumSize = new Size(540, 0); base.Name = "WinListViewPager"; base.Size = new Size(540, 0xd4); base.Load += new EventHandler(this.WinListViewPager_Load); this.contextMenuStrip1.ResumeLayout(false); base.ResumeLayout(false); }