Click here to Skip to main content
16,011,784 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: damn CSocket ! Pin
Christopher Duncan6-Mar-02 16:55
Christopher Duncan6-Mar-02 16:55 
GeneralRe: damn CSocket ! Pin
Nish Nishant6-Mar-02 1:38
sitebuilderNish Nishant6-Mar-02 1:38 
GeneralRe: damn CSocket ! Pin
Mauricio Ritter6-Mar-02 1:59
Mauricio Ritter6-Mar-02 1:59 
GeneralRe: damn CSocket ! Pin
Nish Nishant6-Mar-02 2:02
sitebuilderNish Nishant6-Mar-02 2:02 
GeneralRe: damn CSocket ! Pin
6-Mar-02 1:20
suss6-Mar-02 1:20 
GeneralRe: damn CSocket ! Pin
Nish Nishant6-Mar-02 1:36
sitebuilderNish Nishant6-Mar-02 1:36 
GeneralRe: damn CSocket ! Pin
6-Mar-02 2:39
suss6-Mar-02 2:39 
GeneralRe: damn CSocket ! Pin
6-Mar-02 1:03
suss6-Mar-02 1:03 
Your code in the dialog based app worked because the app has a message pump. CSocket uses a hidden window. The OnAccept method will only be called when messages got processed. Your nt service most likely does not have a message pump.

A simple solution to this problem is

1) Keep your code in the dialog based app.
2) Make sure the dialog based app does not need user intervention (no modal message box, etc.)
3) Start the dialog based app from a special nt service.

Good luck.
GeneralRe: damn CSocket ! Pin
Giles6-Mar-02 2:48
Giles6-Mar-02 2:48 
GeneralI am a chinese boy,give me a hand.thank you! Pin
big20025-Mar-02 23:59
big20025-Mar-02 23:59 
GeneralRe: I am a chinese boy,give me a hand.thank you! Pin
Mazdak6-Mar-02 0:24
Mazdak6-Mar-02 0:24 
GeneralRe: I am a chinese boy,give me a hand.thank you! Pin
Christian Graus6-Mar-02 10:27
protectorChristian Graus6-Mar-02 10:27 
GeneralRe: I am a chinese boy,give me a hand.thank you! Pin
Mazdak6-Mar-02 22:30
Mazdak6-Mar-02 22:30 
GeneralRe: I am a chinese boy,give me a hand.thank you! Pin
Christian Graus7-Mar-02 9:25
protectorChristian Graus7-Mar-02 9:25 
GeneralRe: I am a chinese boy,give me a hand.thank you! Pin
Nish Nishant6-Mar-02 0:36
sitebuilderNish Nishant6-Mar-02 0:36 
QuestionHow can i know if a given PID have a window & how to get the handle of that window ? Pin
5-Mar-02 23:54
suss5-Mar-02 23:54 
AnswerRe: How can i know if a given PID have a window & how to get the handle of that window ? Pin
Tomasz Sowinski5-Mar-02 23:59
Tomasz Sowinski5-Mar-02 23:59 
GeneralRe: How can i know if a given PID have a window & how to get the handle of that window ? Pin
Nish Nishant6-Mar-02 0:33
sitebuilderNish Nishant6-Mar-02 0:33 
GeneralRe: How can i know if a given PID have a window & how to get the handle of that window ? Pin
Tomasz Sowinski6-Mar-02 0:54
Tomasz Sowinski6-Mar-02 0:54 
AnswerThanx guys Pin
6-Mar-02 1:46
suss6-Mar-02 1:46 
GeneralDetecting when running from the command line Pin
Parish5-Mar-02 23:16
Parish5-Mar-02 23:16 
GeneralRe: Detecting when running from the command line Pin
Nish Nishant5-Mar-02 23:24
sitebuilderNish Nishant5-Mar-02 23:24 
GeneralRe: Detecting when running from the command line Pin
Parish5-Mar-02 23:54
Parish5-Mar-02 23:54 
GeneralRe: Detecting when running from the command line Pin
moliate6-Mar-02 1:05
moliate6-Mar-02 1:05 
GeneralRe: Detecting when running from the command line Pin
Joel Lucsy6-Mar-02 4:52
Joel Lucsy6-Mar-02 4:52 

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.