Click here to Skip to main content
15,920,513 members
Home / Discussions / C#
   

C#

 
GeneralRe: form Authenication with users in databse Pin
saud_a_k17-May-06 19:01
saud_a_k17-May-06 19:01 
GeneralRe: form Authenication with users in databse Pin
Colin Angus Mackay17-May-06 23:42
Colin Angus Mackay17-May-06 23:42 
GeneralRe: form Authenication with users in databse Pin
Colin Angus Mackay17-May-06 23:42
Colin Angus Mackay17-May-06 23:42 
AnswerRe: form Authenication with users in databse Pin
Colin Angus Mackay17-May-06 23:45
Colin Angus Mackay17-May-06 23:45 
GeneralRe: form Authenication with users in databse Pin
saud_a_k18-May-06 0:17
saud_a_k18-May-06 0:17 
QuestionDotNetNuke Skin Pin
Kakuji17-May-06 18:41
Kakuji17-May-06 18:41 
AnswerRe: DotNetNuke Skin Pin
leppie17-May-06 19:10
leppie17-May-06 19:10 
QuestionAdding new Rows to the Data base table Pin
Ashraj198217-May-06 18:21
Ashraj198217-May-06 18:21 
Hi

Can any one please tell me how to add the new rows to the existing table with the values using SqlAdapter and Data Row with out using insert statement.

DataSet dset = new DataSet("DBTable");
DataTable dbtable = new DataTable("DBTable"); dset.Tables.Add(dbtable);
SqlCommand dbcommand = new SqlCommand();
dbcommand.CommandText ="select * from DBTable";
dbcommand.Connection = myConnection;
SqlDataAdapter dbDA = new SqlDataAdapter(dbcommand);
dbDA.TableMappings.Add("Table", "DBTable");
dbDA.Fill(dset, "DBTable");
DataRow row;
row = dbtable.NewRow();
row["FileName"] = DBfile;
row["Meters"] = IMeter;
dbtable.Rows.Add(row);
dbDA.Update(dset);

This above code throws exception called "Update requires a valid InsertCommand when passed DataRow collection with new rows." any Idea?

AnswerRe: Adding new Rows to the Data base table Pin
leppie17-May-06 19:12
leppie17-May-06 19:12 
GeneralRe: Adding new Rows to the Data base table Pin
rah_sin17-May-06 19:17
professionalrah_sin17-May-06 19:17 
GeneralRe: Adding new Rows to the Data base table Pin
leppie17-May-06 19:28
leppie17-May-06 19:28 
Questionhow to user mail merge feature of microsoft word from c# Pin
Amrit pal Singh17-May-06 18:19
Amrit pal Singh17-May-06 18:19 
QuestionSending multiple files through same TCP connection! Pin
eyej17-May-06 15:36
eyej17-May-06 15:36 
AnswerRe: Sending multiple files through same TCP connection! Pin
led mike17-May-06 18:15
led mike17-May-06 18:15 
AnswerRe: Sending multiple files through same TCP connection! Pin
leppie17-May-06 19:07
leppie17-May-06 19:07 
GeneralRe: Sending multiple files through same TCP connection! Pin
eyej18-May-06 2:08
eyej18-May-06 2:08 
Questionhow to embedd or bind any file to my app at runtime ? Pin
hdv21217-May-06 13:14
hdv21217-May-06 13:14 
AnswerRe: how to embedd or bind any file to my app at runtime ? Pin
Saqib Mehmood17-May-06 18:17
Saqib Mehmood17-May-06 18:17 
GeneralRe: how to embedd or bind any file to my app at runtime ? Pin
hdv21217-May-06 19:55
hdv21217-May-06 19:55 
GeneralRe: how to embedd or bind any file to my app at runtime ? Pin
Saqib Mehmood17-May-06 20:08
Saqib Mehmood17-May-06 20:08 
GeneralRe: how to embedd or bind any file to my app at runtime ? Pin
hdv21217-May-06 22:56
hdv21217-May-06 22:56 
QuestionCustom User Control and VS.NET 2005 Pin
Drew McGhie17-May-06 12:00
Drew McGhie17-May-06 12:00 
AnswerRe: Custom User Control and VS.NET 2005 Pin
Ed.Poore17-May-06 12:09
Ed.Poore17-May-06 12:09 
GeneralRe: Custom User Control and VS.NET 2005 Pin
Drew McGhie18-May-06 3:22
Drew McGhie18-May-06 3:22 
AnswerRe: Custom User Control and VS.NET 2005 Pin
microsoc17-May-06 19:58
microsoc17-May-06 19:58 

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.