Click here to Skip to main content
15,884,472 members
Home / Discussions / C#
   

C#

 
QuestionSending mail from yahoo thru application Pin
Hum Dum26-Feb-10 0:26
Hum Dum26-Feb-10 0:26 
AnswerRe: Sending mail from yahoo thru application Pin
Bernhard Hiller26-Feb-10 2:22
Bernhard Hiller26-Feb-10 2:22 
QuestionGeneric List Pin
spankyleo12325-Feb-10 23:51
spankyleo12325-Feb-10 23:51 
AnswerRe: Generic List Pin
Pete O'Hanlon25-Feb-10 23:57
mvePete O'Hanlon25-Feb-10 23:57 
GeneralRe: Generic List [modified] Pin
spankyleo12326-Feb-10 0:12
spankyleo12326-Feb-10 0:12 
GeneralRe: Generic List Pin
Paulo Zemek26-Feb-10 1:47
mvaPaulo Zemek26-Feb-10 1:47 
GeneralRe: Generic List Pin
Pete O'Hanlon26-Feb-10 1:56
mvePete O'Hanlon26-Feb-10 1:56 
GeneralRe: Generic List Pin
Searril26-Feb-10 4:38
Searril26-Feb-10 4:38 
"Cannot add items to the combobox when a datasource is assigned"

You need to add the blank row to a datatable before you bind it to the combobox.

This is off the top of my head so will need debugged obviously but you will get the idea:

SqlConnection MyConnection = new SqlConnection(PublicVars.ConnectionString);
                MyConnection.Open();

                SqlDataAdapter sqlDA1 = new SqlDataAdapter("SELECT ItemID FROM some_items", MyConnection);
                DataSet sqlDS = new DataSet();

                sqlDA1.Fill(sqlDS, "some_items");
                DataTable tblItems= sqlDS.Tables["some_items"];

                DataRow NewRow = tblItems.NewRow();
                NewRow[0] = "-- Click To Select --";
                tblItems.Rows.InsertAt(NewRow, 0);

                cboItems.DataSource = tblItems;
                cboItems.DisplayMember = "ItemID";
                cboItems.ValueMember = "ItemID";
                cboItems.SelectedIndex = 0;

                MyConnection.Dispose();


You should get the idea.
Question[SOLVED] I can't figure out EmitCalli of ILGenerator [modified] Pin
blackblizzard25-Feb-10 23:24
blackblizzard25-Feb-10 23:24 
AnswerRe: I can't figure out EmitCalli of ILGenerator Pin
Kythen26-Feb-10 13:08
Kythen26-Feb-10 13:08 
Question[SOLVED] How can I emit a call to a delegate whose type is unfinished at the time of the emit? [modified] Pin
blackblizzard28-Feb-10 6:28
blackblizzard28-Feb-10 6:28 
AnswerRe: How can I emit a call to a delegate whose type is unfinished at the time of the emit? Pin
blackblizzard4-Mar-10 21:23
blackblizzard4-Mar-10 21:23 
QuestionWebbrowser Control - selected Image Pin
hoernchenmeister25-Feb-10 21:25
hoernchenmeister25-Feb-10 21:25 
QuestionHow to Read a .doc in C# Pin
gouthami chintala25-Feb-10 20:48
gouthami chintala25-Feb-10 20:48 
AnswerMessage Removed Pin
25-Feb-10 20:50
stancrm25-Feb-10 20:50 
GeneralMessage Removed Pin
26-Feb-10 2:34
gouthami chintala26-Feb-10 2:34 
GeneralRe: How to Read a .doc in C# Pin
Dave Kreskowiak26-Feb-10 3:26
mveDave Kreskowiak26-Feb-10 3:26 
AnswerRe: How to Read a .doc in C# Pin
Mohammad Dayyan25-Feb-10 20:53
Mohammad Dayyan25-Feb-10 20:53 
AnswerRe: How to Read a .doc in C# Pin
Saksida Bojan25-Feb-10 21:03
Saksida Bojan25-Feb-10 21:03 
AnswerRe: How to Read a .doc in C# Pin
Kythen26-Feb-10 12:34
Kythen26-Feb-10 12:34 
QuestionCrystal Report XI issue Pin
Raza Hussain25-Feb-10 20:47
Raza Hussain25-Feb-10 20:47 
AnswerRe: Crystal Report XI issue Pin
Mohammad Dayyan25-Feb-10 20:57
Mohammad Dayyan25-Feb-10 20:57 
GeneralRe: Crystal Report XI issue Pin
Raza Hussain28-Feb-10 23:11
Raza Hussain28-Feb-10 23:11 
Questionblood Pressure Pin
Jassim Rahma25-Feb-10 20:44
Jassim Rahma25-Feb-10 20:44 
AnswerMessage Closed Pin
25-Feb-10 20:53
stancrm25-Feb-10 20:53 

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.