Click here to Skip to main content
15,891,033 members
Home / Discussions / C#
   

C#

 
QuestionGridviw - my rowCommand does not run Pin
simsen30-Jun-08 0:42
simsen30-Jun-08 0:42 
AnswerRe: Gridviw - my rowCommand does not run Pin
simsen30-Jun-08 0:54
simsen30-Jun-08 0:54 
QuestionSystem.Diagnostics.Process used to start a c++ makefile ! Big issue ! Pin
ozzox30-Jun-08 0:37
ozzox30-Jun-08 0:37 
AnswerRe: System.Diagnostics.Process used to start a c++ makefile ! Big issue ! Pin
Daniel Grunwald30-Jun-08 2:24
Daniel Grunwald30-Jun-08 2:24 
GeneralRe: System.Diagnostics.Process used to start a c++ makefile ! Big issue ! Pin
ozzox30-Jun-08 15:43
ozzox30-Jun-08 15:43 
AnswerRe: System.Diagnostics.Process used to start a c++ makefile ! Big issue ! Pin
leppie30-Jun-08 5:10
leppie30-Jun-08 5:10 
QuestionWeird data bindings issue Pin
Harvey Saayman30-Jun-08 0:22
Harvey Saayman30-Jun-08 0:22 
AnswerRe: Weird data bindings issue Pin
Vimalsoft(Pty) Ltd30-Jun-08 0:58
professionalVimalsoft(Pty) Ltd30-Jun-08 0:58 
Good Afternoon HarveySaayman

Well if you want your Combobox to Display data from one Data Source , it will be Simple, but the Behavior of Combox boxes in the Form will do , that am not sure why, but if you a for example searching based on what is selected , it will not give you a Problem, dont worry about it, i have never experienced a problem before and i understand what you mean. and if you want to bind your data fied to your Combobox, next time you can do it like this


private void dataBindTimeCatComboBoxes()
{
//create a new dataset     
DataSet dataSet = new DataSet();
//create sql command    
SqlCommand selectCommand = new SqlCommand("Proc_SelectTimeCategoryName", sqlConn); 
selectCommand.CommandType = CommandType.StoredProcedure;  
//create data adapter 
SqlDataAdapter dataAdapter = new SqlDataAdapter(); 
dataAdapter.SelectCommand = selectCommand;  
//Fill the dataset    
dataAdapter.Fill(dataSet, "tCat");      
//Data Bind the combo boxes    //   

//You Should Bind it like this 
/*
 * comboBox6.DataSource = datasetname;  
   comboBox6.DisplayMember = "Tablename.Field"; 
*/
comboBox2.DataSource = tCatTable;   
comboBox2.DisplayMember  = "tCat.TCat_Name_VC30";  

comboBox3.DataSource = tCatTable;  
comboBox3.DisplayMember = "tCat.TCat_Name_VC30";  

comboBox4.DataSource = tCatTable;  
comboBox4.DisplayMember = "tCat.TCat_Name_VC30";   

comboBox5.DataSource = tCatTable; 
comboBox5.DisplayMember = "tCat.TCat_Name_VC30";   

comboBox6.DataSource = tCatTable;  
comboBox6.DisplayMember = "tCat.TCat_Name_VC30"; 
}


Sometimes its not Necessaryto use datatable .remove that ValueMember property.

Hope it helps

Vuyiswa Maseko,

Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding

VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za


AnswerRe: Weird data bindings issue Pin
Mbah Dhaim30-Jun-08 1:11
Mbah Dhaim30-Jun-08 1:11 
GeneralRe: Weird data bindings issue Pin
Harvey Saayman30-Jun-08 1:14
Harvey Saayman30-Jun-08 1:14 
QuestioncheckBox & ListView Pin
laziale30-Jun-08 0:20
laziale30-Jun-08 0:20 
AnswerRe: checkBox & ListView Pin
Vimalsoft(Pty) Ltd30-Jun-08 1:00
professionalVimalsoft(Pty) Ltd30-Jun-08 1:00 
GeneralRe: checkBox & ListView Pin
laziale30-Jun-08 1:19
laziale30-Jun-08 1:19 
QuestionDetermine incorrect String.Format format Pin
Stevo Z29-Jun-08 23:59
Stevo Z29-Jun-08 23:59 
AnswerRe: Determine incorrect String.Format format Pin
PIEBALDconsult30-Jun-08 5:10
mvePIEBALDconsult30-Jun-08 5:10 
QuestionSQL connection execute what? Pin
laziale29-Jun-08 23:13
laziale29-Jun-08 23:13 
AnswerRe: SQL connection execute what? Pin
Christian Graus29-Jun-08 23:22
protectorChristian Graus29-Jun-08 23:22 
GeneralRe: SQL connection execute what? Pin
laziale29-Jun-08 23:28
laziale29-Jun-08 23:28 
GeneralRe: SQL connection execute what? Pin
Christian Graus29-Jun-08 23:36
protectorChristian Graus29-Jun-08 23:36 
AnswerRe: SQL connection execute what? Pin
Mbah Dhaim29-Jun-08 23:27
Mbah Dhaim29-Jun-08 23:27 
GeneralRe: SQL connection execute what? Pin
Colin Angus Mackay29-Jun-08 23:31
Colin Angus Mackay29-Jun-08 23:31 
JokeRe: SQL connection execute what? Pin
Mbah Dhaim29-Jun-08 23:37
Mbah Dhaim29-Jun-08 23:37 
GeneralRe: SQL connection execute what? Pin
laziale29-Jun-08 23:34
laziale29-Jun-08 23:34 
GeneralRe: SQL connection execute what? Pin
Christian Graus29-Jun-08 23:39
protectorChristian Graus29-Jun-08 23:39 
AnswerRe: SQL connection execute what? Pin
Colin Angus Mackay29-Jun-08 23:30
Colin Angus Mackay29-Jun-08 23:30 

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.