Click here to Skip to main content
15,902,114 members
Home / Discussions / C#
   

C#

 
GeneralRe: drawing multi line Pin
Henry Minute21-Aug-09 11:41
Henry Minute21-Aug-09 11:41 
GeneralRe: drawing multi line Pin
mgroses22-Aug-09 6:18
mgroses22-Aug-09 6:18 
AnswerRe: drawing multi line Pin
TAFIN22-Aug-09 20:21
TAFIN22-Aug-09 20:21 
QuestionHow to select right size icon from imagelist with multiple resolution icons Pin
shultas21-Aug-09 4:43
shultas21-Aug-09 4:43 
AnswerRe: How to select right size icon from imagelist with multiple resolution icons Pin
Saksida Bojan21-Aug-09 5:31
Saksida Bojan21-Aug-09 5:31 
GeneralRe: How to select right size icon from imagelist with multiple resolution icons Pin
shultas22-Aug-09 2:26
shultas22-Aug-09 2:26 
QuestionHow to insert the values in to two database tables in C# Pin
himanshu_roy8121-Aug-09 3:29
himanshu_roy8121-Aug-09 3:29 
AnswerRe: How to insert the values in to two database tables in C# Pin
Pete O'Hanlon21-Aug-09 3:37
mvePete O'Hanlon21-Aug-09 3:37 
himanshu_roy81 wrote:
How to insert the values in to two database tables in C#.


Technically, you do this with 2 SQL commands, not C#, but I get what you mean. Basically, you need to create two insert statements (make sure you use parameterized queries), and then you run them both in order - you can use one command object for this (use the ExecuteNonQuery method to perform it).

I haven't specified which of the command classes to use because you haven't specified which database you're hitting, i.e. if it's SQL Server, you'd use SqlCommand. (If both of the inserts have to be performed in one transaction, you'd wrap them up in a transaction).

"WPF has many lovers. It's a veritable porn star!" - Josh Smith

As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.


My blog | My articles | MoXAML PowerToys | Onyx



AnswerRe: How to insert the values in to two database tables in C# Pin
Keith Barrow21-Aug-09 3:38
professionalKeith Barrow21-Aug-09 3:38 
AnswerRe: How to insert the values in to two database tables in C# Pin
PIEBALDconsult21-Aug-09 4:38
mvePIEBALDconsult21-Aug-09 4:38 
Questionhow to redirect the page when the particular cell in the datagridview is double clikced Pin
Anjani Poornima21-Aug-09 3:26
Anjani Poornima21-Aug-09 3:26 
AnswerRe: how to redirect the page when the particular cell in the datagridview is double clikced Pin
Henry Minute21-Aug-09 5:51
Henry Minute21-Aug-09 5:51 
GeneralRe: how to redirect the page when the particular cell in the datagridview is double clikced Pin
Anjani Poornima21-Aug-09 22:03
Anjani Poornima21-Aug-09 22:03 
GeneralRe: how to redirect the page when the particular cell in the datagridview is double clikced Pin
Henry Minute22-Aug-09 2:30
Henry Minute22-Aug-09 2:30 
AnswerRe: how to redirect the page when the particular cell in the datagridview is double clikced Pin
Saksida Bojan21-Aug-09 6:32
Saksida Bojan21-Aug-09 6:32 
Questionhow to call method of mdi child form from mdi parent form Pin
Tridip Bhattacharjee21-Aug-09 3:21
professionalTridip Bhattacharjee21-Aug-09 3:21 
AnswerRe: how to call method of mdi child form from mdi parent form Pin
0x3c021-Aug-09 3:27
0x3c021-Aug-09 3:27 
QuestionUnable to read Private Key as XML String Pin
Jadhav Ajay21-Aug-09 2:25
professionalJadhav Ajay21-Aug-09 2:25 
AnswerRe: Unable to read Private Key as XML String Pin
Keith Barrow21-Aug-09 3:04
professionalKeith Barrow21-Aug-09 3:04 
GeneralRe: Unable to read Private Key as XML String Pin
Jadhav Ajay22-Aug-09 0:37
professionalJadhav Ajay22-Aug-09 0:37 
QuestionObjectDisposedException within a while loop? Pin
Trapper-Hell21-Aug-09 1:56
Trapper-Hell21-Aug-09 1:56 
AnswerRe: ObjectDisposedException within a while loop? Pin
Gideon Engelberth21-Aug-09 3:46
Gideon Engelberth21-Aug-09 3:46 
AnswerRe: ObjectDisposedException within a while loop? Pin
Luc Pattyn21-Aug-09 4:21
sitebuilderLuc Pattyn21-Aug-09 4:21 
GeneralRe: ObjectDisposedException within a while loop? Pin
Trapper-Hell23-Aug-09 20:19
Trapper-Hell23-Aug-09 20:19 
GeneralRe: ObjectDisposedException within a while loop? Pin
Luc Pattyn24-Aug-09 2:46
sitebuilderLuc Pattyn24-Aug-09 2:46 

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.