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

C#

 
AnswerRe: combo+sql+C# Pin
Paul Conrad23-Nov-07 7:38
professionalPaul Conrad23-Nov-07 7:38 
Questionstore procedure problem [modified] Pin
Raza Hussain23-Nov-07 4:50
Raza Hussain23-Nov-07 4:50 
AnswerRe: store procedure problem Pin
Rob Philpott23-Nov-07 5:27
Rob Philpott23-Nov-07 5:27 
QuestionSql Table Foriegn Key Problem in C# Pin
sajid.salim.khan23-Nov-07 4:47
sajid.salim.khan23-Nov-07 4:47 
AnswerRe: Sql Table Foriegn Key Problem in C# Pin
Raza Hussain23-Nov-07 5:00
Raza Hussain23-Nov-07 5:00 
Questionhow can I shutdown the pc ? Pin
The Glory23-Nov-07 4:38
The Glory23-Nov-07 4:38 
AnswerRe: how can I shutdown the pc ? Pin
Kristian Sixhøj23-Nov-07 4:49
Kristian Sixhøj23-Nov-07 4:49 
AnswerRe: how can I shutdown the pc ? Pin
Anthony Mushrow23-Nov-07 5:56
professionalAnthony Mushrow23-Nov-07 5:56 
And an even easier way (assuming your using XP, and probably Vista, but who knows) is to use:

Process.Start("shutdown", "some arguments");

And the arguments are:

-i                      Display GUI interface, must be the first option
-l                      Log off (cannot be used with -m option)
-s                      Shutdown the computer
-r                      Shutdown and restart the computer
-a                      Abort a system shutdown
-m \\computername       Remote computer to shutdown/restart/abort
-t xx                   Set timeout for shutdown to xx seconds
-c "comment"            Shutdown comment (maximum of 127 characters)
-f                      Forces running applications to close without warning


so:

Process.Start("shutdown", "-s");

Would shut down the machine.

My current favourite word is: PIE!

Good ol' pie, it's been a while.

QuestionDeleting row in Event Pin
baerten23-Nov-07 4:20
baerten23-Nov-07 4:20 
QuestionLoad an image from a file Pin
SeeBees23-Nov-07 3:50
SeeBees23-Nov-07 3:50 
AnswerRe: Load an image from a file Pin
Dave Kreskowiak23-Nov-07 5:33
mveDave Kreskowiak23-Nov-07 5:33 
GeneralRe: Load an image from a file Pin
SeeBees23-Nov-07 17:23
SeeBees23-Nov-07 17:23 
GeneralRe: Load an image from a file Pin
Dave Kreskowiak24-Nov-07 4:14
mveDave Kreskowiak24-Nov-07 4:14 
AnswerRe: Load an image from a file Pin
Anthony Mushrow23-Nov-07 7:34
professionalAnthony Mushrow23-Nov-07 7:34 
GeneralRe: Load an image from a file Pin
SeeBees23-Nov-07 17:32
SeeBees23-Nov-07 17:32 
GeneralRe: Load an image from a file Pin
Anthony Mushrow24-Nov-07 1:51
professionalAnthony Mushrow24-Nov-07 1:51 
QuestionError Pin
minniemooo23-Nov-07 3:15
minniemooo23-Nov-07 3:15 
AnswerRe: Error Pin
Andrei Ungureanu23-Nov-07 3:18
Andrei Ungureanu23-Nov-07 3:18 
AnswerRe: Error Pin
Anthony Mushrow23-Nov-07 3:19
professionalAnthony Mushrow23-Nov-07 3:19 
AnswerRe: Error Pin
Vasudevan Deepak Kumar23-Nov-07 3:38
Vasudevan Deepak Kumar23-Nov-07 3:38 
AnswerRe: Error Pin
kkadir23-Nov-07 4:26
kkadir23-Nov-07 4:26 
QuestionDisable PDF Print button from C# Pin
cosmoteco23-Nov-07 3:14
cosmoteco23-Nov-07 3:14 
AnswerRe: Disable PDF Print button from C# Pin
Vasudevan Deepak Kumar23-Nov-07 3:42
Vasudevan Deepak Kumar23-Nov-07 3:42 
GeneralRe: Disable PDF Print button from C# Pin
cosmoteco23-Nov-07 4:33
cosmoteco23-Nov-07 4:33 
GeneralRe: Disable PDF Print button from C# Pin
Dave Kreskowiak23-Nov-07 5:31
mveDave Kreskowiak23-Nov-07 5:31 

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.