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

C#

 
QuestionInheriting a class and using property grid Pin
kselman3-Oct-06 20:38
kselman3-Oct-06 20:38 
AnswerRe: Inheriting a class and using property grid Pin
LongRange.Shooter4-Oct-06 7:09
LongRange.Shooter4-Oct-06 7:09 
QuestionDetermining file state (open or closed) Pin
Nitin19813-Oct-06 20:20
Nitin19813-Oct-06 20:20 
AnswerRe: Determining file state (open or closed) Pin
Steve :)3-Oct-06 20:46
Steve :)3-Oct-06 20:46 
GeneralRe: Determining file state (open or closed) Pin
Nitin19813-Oct-06 21:04
Nitin19813-Oct-06 21:04 
AnswerRe: Determining file state (open or closed) Pin
S. Senthil Kumar4-Oct-06 4:29
S. Senthil Kumar4-Oct-06 4:29 
QuestionPrevent Application Close / Detech Application started Pin
Major_A3983-Oct-06 16:14
Major_A3983-Oct-06 16:14 
AnswerRe: Prevent Application Close / Detech Application started Pin
LongRange.Shooter4-Oct-06 7:12
LongRange.Shooter4-Oct-06 7:12 
Major_A398 wrote:
I'm looking for a way in C#.NET 2.0 to not allow my application from being closed by Task Manager by doing an End Task. Was thinking about displaying an error message saying you can't close this task. Any Ideas?


On your parent form, implement a handler for the Closing event. The Closing EventArg allows you to set e.Cancel = true;


Major_A398 wrote:
Also I'm looking for a way to detect certain applications are started and not allow them to start with a message box that says something like "Not aloud to run this app".


This would require unsafe code hooked into the WinAPI. Can't help you there. An alternative is to have all applications as MDI children and the controller is the MDIParent. In this scenario you can do your security handling for each child application within you.
AnswerRe: Prevent Application Close / Detech Application started Pin
Major_A3984-Oct-06 12:35
Major_A3984-Oct-06 12:35 
GeneralRe: Prevent Application Close / Detech Application started Pin
LongRange.Shooter4-Oct-06 14:52
LongRange.Shooter4-Oct-06 14:52 
GeneralRe: Prevent Application Close / Detech Application started Pin
Major_A3984-Oct-06 15:05
Major_A3984-Oct-06 15:05 
QuestionHow to implement a ReceiveCallback function??? Pin
CTaylor893-Oct-06 14:03
CTaylor893-Oct-06 14:03 
AnswerRe: How to implement a ReceiveCallback function??? Pin
Stefan Troschuetz3-Oct-06 21:14
Stefan Troschuetz3-Oct-06 21:14 
GeneralRe: How to implement a ReceiveCallback function??? Pin
CTaylor894-Oct-06 8:45
CTaylor894-Oct-06 8:45 
AnswerRe: remoting in c# Pin
LongRange.Shooter4-Oct-06 7:13
LongRange.Shooter4-Oct-06 7:13 
QuestionUnit Testing Pin
Jamie Nordmeyer3-Oct-06 12:56
Jamie Nordmeyer3-Oct-06 12:56 
AnswerRe: Unit Testing Pin
LongRange.Shooter4-Oct-06 7:15
LongRange.Shooter4-Oct-06 7:15 
GeneralRe: Unit Testing Pin
Jamie Nordmeyer4-Oct-06 7:17
Jamie Nordmeyer4-Oct-06 7:17 
QuestionPath of a current process? Pin
sundar1563-Oct-06 12:47
sundar1563-Oct-06 12:47 
AnswerRe: Path of a current process? Pin
User 66583-Oct-06 13:03
User 66583-Oct-06 13:03 
Questionbold and italic Pin
mostafasafy3-Oct-06 10:09
mostafasafy3-Oct-06 10:09 
AnswerRe: bold and italic Pin
Nader Elshehabi3-Oct-06 10:25
Nader Elshehabi3-Oct-06 10:25 
QuestionMODI Error Pin
smarttom993-Oct-06 9:30
smarttom993-Oct-06 9:30 
AnswerRe: MODI Error Pin
Nader Elshehabi3-Oct-06 9:39
Nader Elshehabi3-Oct-06 9:39 
QuestionWriting redirected output from an unmanaged executable to a windows form control Pin
erikash3-Oct-06 7:54
erikash3-Oct-06 7:54 

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.