Click here to Skip to main content
15,901,505 members
Home / Discussions / C#
   

C#

 
AnswerRe: Deploying Database [modified] Pin
PIEBALDconsult23-Jan-09 13:05
mvePIEBALDconsult23-Jan-09 13:05 
AnswerRe: Deploying Database Pin
Alex Casals23-Jan-09 23:32
professionalAlex Casals23-Jan-09 23:32 
QuestionC# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
Wheels01223-Jan-09 9:13
Wheels01223-Jan-09 9:13 
AnswerRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
DaveyM6923-Jan-09 9:16
professionalDaveyM6923-Jan-09 9:16 
GeneralRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
Wheels01223-Jan-09 9:29
Wheels01223-Jan-09 9:29 
GeneralRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
DaveyM6923-Jan-09 10:03
professionalDaveyM6923-Jan-09 10:03 
GeneralRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
Wheels01226-Jan-09 1:32
Wheels01226-Jan-09 1:32 
GeneralRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
Wheels01228-Jan-09 2:05
Wheels01228-Jan-09 2:05 
Hi Dave.

I have the following code:

ds = d.GeneralDropDown("Dept");

foreach (DataRow dr in ds.Tables[0].Rows)
{
//cboDeptID.Items.Add(dr[constrDeptID].ToString());
//cboDepartment.Items.Add(dr[constrDeptID].ToString() + " " + dr[constrDeptColumn].ToString());
cboDepartment.Items.Add(dr[constrDeptColumn].ToString());
cboDepartment.DisplayMember = dr[constrDeptColumn].ToString();
cboDepartment.ValueMember = dr[constrDeptID].ToString();
}

private void cboDeptID_SelectedIndexChanged(object sender, EventArgs e)
{
//ds = new DataSet();
//ds = d.FillDataGrid(this.cboDepartment,this.cboAcronym);
MessageBox.Show(this.cboDepartment.ValueMember);
MessageBox.Show(this.cboDepartment.DisplayMember);
}

Am I using the DisplayMemeber and ValueMember correctly? The combobox is poppulated, but the MessageBoxes don't come up when the value in the combobox changes.

Any ideas? WHEELS
GeneralRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
DaveyM6928-Jan-09 7:08
professionalDaveyM6928-Jan-09 7:08 
GeneralRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
Wheels01228-Jan-09 8:37
Wheels01228-Jan-09 8:37 
GeneralRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
DaveyM6928-Jan-09 9:41
professionalDaveyM6928-Jan-09 9:41 
GeneralRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
DaveyM6930-Jan-09 9:28
professionalDaveyM6930-Jan-09 9:28 
GeneralRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
Wheels01230-Jan-09 9:31
Wheels01230-Jan-09 9:31 
GeneralRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
Wheels0124-Feb-09 2:47
Wheels0124-Feb-09 2:47 
GeneralRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
Wheels0124-Feb-09 8:08
Wheels0124-Feb-09 8:08 
GeneralRe: C# Populate Multi column (2) combobox with existing dataset (hide record #) Pin
DaveyM694-Feb-09 13:16
professionalDaveyM694-Feb-09 13:16 
QuestionSplash Screen / Init question Pin
EliottA23-Jan-09 8:50
EliottA23-Jan-09 8:50 
AnswerRe: Splash Screen / Init question Pin
DaveyM6923-Jan-09 9:10
professionalDaveyM6923-Jan-09 9:10 
AnswerRe: Splash Screen / Init question Pin
User 665823-Jan-09 10:01
User 665823-Jan-09 10:01 
QuestionError: RegularExpression can't be found [modified] Pin
u060509423-Jan-09 8:35
u060509423-Jan-09 8:35 
AnswerRe: Error: RegularExpression can't be found Pin
DaveyM6923-Jan-09 8:41
professionalDaveyM6923-Jan-09 8:41 
GeneralRe: Error: RegularExpression can't be found Pin
u060509423-Jan-09 8:43
u060509423-Jan-09 8:43 
GeneralRe: Error: RegularExpression can't be found Pin
DaveyM6923-Jan-09 8:51
professionalDaveyM6923-Jan-09 8:51 
GeneralRe: Error: RegularExpression can't be found Pin
u060509423-Jan-09 8:57
u060509423-Jan-09 8:57 
GeneralRe: Error: RegularExpression can't be found Pin
DaveyM6923-Jan-09 9:06
professionalDaveyM6923-Jan-09 9:06 

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.