Click here to Skip to main content
15,893,161 members
Home / Discussions / C#
   

C#

 
GeneralRe: Multiple forms and datagridviews Pin
Henry Minute26-May-09 13:18
Henry Minute26-May-09 13:18 
GeneralRe: Multiple forms and datagridviews [modified] Pin
bwood202027-May-09 5:44
bwood202027-May-09 5:44 
GeneralRe: Multiple forms and datagridviews Pin
Henry Minute27-May-09 7:20
Henry Minute27-May-09 7:20 
GeneralRe: Multiple forms and datagridviews Pin
Henry Minute27-May-09 10:41
Henry Minute27-May-09 10:41 
GeneralRe: Multiple forms and datagridviews Pin
Henry Minute27-May-09 11:39
Henry Minute27-May-09 11:39 
GeneralRe: Multiple forms and datagridviews Pin
bwood202027-May-09 12:18
bwood202027-May-09 12:18 
GeneralRe: Multiple forms and datagridviews Pin
Henry Minute27-May-09 12:29
Henry Minute27-May-09 12:29 
GeneralRe: Multiple forms and datagridviews Pin
Henry Minute27-May-09 12:35
Henry Minute27-May-09 12:35 
Er..................
I did tell you that I had added two dgv columns, in the designer, didn't I?

No, you say!

ahem:
private void InitializeComponent()
{
    this.components = new System.ComponentModel.Container();
    this.dataGridView1 = new System.Windows.Forms.DataGridView();
    this.btnGetValue = new System.Windows.Forms.Button();
    this.clientColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
    this.standardColumn = new System.Windows.Forms.DataGridViewComboBoxColumn();
    this.headersBindingSource = new System.Windows.Forms.BindingSource(this.components);
    ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
    ((System.ComponentModel.ISupportInitialize)(this.headersBindingSource)).BeginInit();
    this.SuspendLayout();
    //
    // dataGridView1
    //
    this.dataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
    this.dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
    this.clientColumn,
    this.standardColumn});
    this.dataGridView1.Location = new System.Drawing.Point(12, 12);
    this.dataGridView1.Name = "dataGridView1";
    this.dataGridView1.Size = new System.Drawing.Size(284, 171);
    this.dataGridView1.TabIndex = 0;
    //
    // btnGetValue
    //
    this.btnGetValue.Location = new System.Drawing.Point(154, 236);
    this.btnGetValue.Name = "btnGetValue";
    this.btnGetValue.Size = new System.Drawing.Size(75, 23);
    this.btnGetValue.TabIndex = 1;
    this.btnGetValue.Text = "Value";
    this.btnGetValue.UseVisualStyleBackColor = true;
    this.btnGetValue.Click += new System.EventHandler(this.btnGetValue_Click);
    //
    // clientColumn
    //
    this.clientColumn.HeaderText = "Client Header";
    this.clientColumn.Name = "clientColumn";
    //
    // standardColumn
    //
    this.standardColumn.HeaderText = "Standard Header";
    this.standardColumn.Name = "standardColumn";
    //
    // ListEditorForm
    //
    this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 14F);
    this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
    this.ClientSize = new System.Drawing.Size(422, 288);
    this.Controls.Add(this.btnGetValue);
    this.Controls.Add(this.dataGridView1);
    this.Name = "ListEditorForm";
    this.Text = "List Editor";
    this.Load += new System.EventHandler(this.ListEditorForm_Load);
    ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).EndInit();
    ((System.ComponentModel.ISupportInitialize)(this.headersBindingSource)).EndInit();
    this.ResumeLayout(false);

}

#endregion

private System.Windows.Forms.DataGridView dataGridView1;
private System.Windows.Forms.Button btnGetValue;
private System.Windows.Forms.BindingSource headersBindingSource;
private System.Windows.Forms.DataGridViewTextBoxColumn clientColumn;
private System.Windows.Forms.DataGridViewComboBoxColumn standardColumn;


Here is the designer code for the first form. Just replace the code in your form1.designer.cs file with it.

I think I'll go for a lie down in a dark room now.

Henry Minute

Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”

GeneralRe: Multiple forms and datagridviews Pin
bwood202027-May-09 13:02
bwood202027-May-09 13:02 
GeneralRe: Multiple forms and datagridviews Pin
bwood202029-May-09 5:27
bwood202029-May-09 5:27 
GeneralRe: Multiple forms and datagridviews Pin
bwood202018-Jun-09 12:06
bwood202018-Jun-09 12:06 
QuestionCheck if frame in webclient is done loading Pin
Member 441789215-May-09 4:25
Member 441789215-May-09 4:25 
Questionposting data to remote URL using WebBrowser Pin
shabya15-May-09 2:49
shabya15-May-09 2:49 
QuestionConvert EBCDIC to ASCII and vice versa Pin
deep715-May-09 2:15
deep715-May-09 2:15 
AnswerRe: Convert EBCDIC to ASCII and vice versa Pin
OriginalGriff15-May-09 2:23
mveOriginalGriff15-May-09 2:23 
GeneralRe: Convert EBCDIC to ASCII and vice versa Pin
deep715-May-09 2:39
deep715-May-09 2:39 
GeneralRe: Convert EBCDIC to ASCII and vice versa Pin
Alan Balkany15-May-09 3:31
Alan Balkany15-May-09 3:31 
AnswerRe: Convert EBCDIC to ASCII and vice versa Pin
Scott Barbour15-May-09 9:59
Scott Barbour15-May-09 9:59 
GeneralRe: Convert EBCDIC to ASCII and vice versa Pin
ishtine188-Jan-10 19:04
ishtine188-Jan-10 19:04 
GeneralRe: Convert EBCDIC to ASCII and vice versa Pin
frank_a3208-Feb-11 11:41
frank_a3208-Feb-11 11:41 
QuestionDatetime picker Pin
KIDYA15-May-09 2:07
KIDYA15-May-09 2:07 
AnswerRe: Datetime picker Pin
Eddy Vluggen15-May-09 2:47
professionalEddy Vluggen15-May-09 2:47 
AnswerRe: Datetime picker Pin
DaveyM6915-May-09 5:27
professionalDaveyM6915-May-09 5:27 
QuestionHow can I optimize this code Pin
MumbleB15-May-09 1:51
MumbleB15-May-09 1:51 
AnswerRe: How can I optimize this code Pin
Tom Deketelaere15-May-09 2:03
professionalTom Deketelaere15-May-09 2:03 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.