Click here to Skip to main content
16,016,345 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionLoading a Dialog resource into another form Dynamically Pin
bobm523-Oct-06 13:35
bobm523-Oct-06 13:35 
AnswerRe: Loading a Dialog resource into another form Dynamically Pin
Mark Salsbery23-Oct-06 13:50
Mark Salsbery23-Oct-06 13:50 
AnswerRe: Loading a Dialog resource into another form Dynamically Pin
Hamid_RT25-Oct-06 19:40
Hamid_RT25-Oct-06 19:40 
Questiondrag and drop into a webbrowser activex control Pin
derek_23-Oct-06 13:22
derek_23-Oct-06 13:22 
Questionsocket connection Pin
nahitan23-Oct-06 13:11
nahitan23-Oct-06 13:11 
AnswerRe: socket connection Pin
Mark Salsbery23-Oct-06 13:38
Mark Salsbery23-Oct-06 13:38 
GeneralRe: socket connection Pin
nahitan23-Oct-06 13:46
nahitan23-Oct-06 13:46 
GeneralRe: socket connection Pin
Mark Salsbery23-Oct-06 13:57
Mark Salsbery23-Oct-06 13:57 
Yes, you'll see the connection in netstat because the socket is still allocated even though it
may be disconnected physically. It will remain in CLOSE_WAIT (waiting for close as the name
implies) until you call closesocket(). Even after calling closesocket(), if there is/was pending
data on the connection it will "linger" by default for I think 120 seconds (so you'll see it in
netstat for that long). To force it to close immediately you can turn off the linger option for
the socket, something like:

// force hard/abortive close
linger Linger;
Linger.l_onoff = 1;
Linger.l_linger = 0;
::setsockopt(hSocket, SOL_SOCKET, SO_LINGER, (const char *)&Linger, sizeof(linger));
::closesocket(hSocket);
hSocket = INVALID_SOCKET;

AnswerRe: socket connection Pin
fat_boy23-Oct-06 23:42
fat_boy23-Oct-06 23:42 
AnswerRe: socket connection Pin
Moak1-Nov-06 3:15
Moak1-Nov-06 3:15 
QuestionMouseWheel Question Pin
Mark F.23-Oct-06 12:33
Mark F.23-Oct-06 12:33 
AnswerRe: MouseWheel Question Pin
Mark Salsbery23-Oct-06 13:16
Mark Salsbery23-Oct-06 13:16 
GeneralRe: MouseWheel Question [fixed] Pin
Mark F.23-Oct-06 15:02
Mark F.23-Oct-06 15:02 
GeneralRe: MouseWheel Question Pin
Mark Salsbery23-Oct-06 15:20
Mark Salsbery23-Oct-06 15:20 
Questionchar* vs vectors vs std::string Pin
Wheatbread23-Oct-06 9:29
Wheatbread23-Oct-06 9:29 
AnswerRe: char* vs vectors vs std::string Pin
Zac Howland23-Oct-06 9:41
Zac Howland23-Oct-06 9:41 
GeneralRe: char* vs vectors vs std::string Pin
led mike23-Oct-06 9:52
led mike23-Oct-06 9:52 
GeneralRe: char* vs vectors vs std::string Pin
Nemanja Trifunovic23-Oct-06 10:00
Nemanja Trifunovic23-Oct-06 10:00 
GeneralRe: char* vs vectors vs std::string Pin
Zac Howland23-Oct-06 11:04
Zac Howland23-Oct-06 11:04 
GeneralRe: char* vs vectors vs std::string Pin
Zac Howland23-Oct-06 10:18
Zac Howland23-Oct-06 10:18 
GeneralRe: char* vs vectors vs std::string Pin
led mike23-Oct-06 11:34
led mike23-Oct-06 11:34 
AnswerRe: char* vs vectors vs std::string Pin
Nemanja Trifunovic23-Oct-06 9:45
Nemanja Trifunovic23-Oct-06 9:45 
AnswerRe: char* vs vectors vs std::string Pin
fat_boy23-Oct-06 23:43
fat_boy23-Oct-06 23:43 
QuestionCDialog access ! Pin
mostafa_pasha23-Oct-06 8:48
mostafa_pasha23-Oct-06 8:48 
QuestionRe: CDialog access ! Pin
David Crow23-Oct-06 9:37
David Crow23-Oct-06 9:37 

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.