Click here to Skip to main content
15,898,010 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralBinarytree Pin
.NetRams26-Aug-04 2:21
.NetRams26-Aug-04 2:21 
GeneralRe: Binarytree Pin
4apai26-Aug-04 2:51
4apai26-Aug-04 2:51 
GeneralCListBox, Items underline Pin
Member 130581126-Aug-04 2:14
Member 130581126-Aug-04 2:14 
GeneralRe: CListBox, Items underline Pin
David Salter26-Aug-04 2:45
David Salter26-Aug-04 2:45 
GeneralRe: CListBox, Items underline Pin
Member 130581126-Aug-04 23:46
Member 130581126-Aug-04 23:46 
GeneralRe: CListBox, Items underline Pin
rotu27-Aug-04 0:37
rotu27-Aug-04 0:37 
GeneralInstallShield Developer 7 launching multiple msi from setup/master msi Pin
TssPrasad26-Aug-04 2:14
sussTssPrasad26-Aug-04 2:14 
GeneralUnable to create a server Pin
Anonymous26-Aug-04 2:08
Anonymous26-Aug-04 2:08 
hi,
i was creating a server from CSocket but whenever the client connects to the server, my server dialog box will automatically close itself. i wonder of there is anything wrong with my code?

i have a mysocket class, below is part of the code:

void mysocket::OnAccept(int nErrorCode)
{
if ( nErrorCode == 0 )
( ( CMultiAPIDlg* ) m_pWnd ) -> onaccept( ) ;

CSocket::OnAccept(nErrorCode);
}

in my code for the dialog box, when user press connect, the following function is evoked:

void CMultiAPIDlg::OnBConnect()
{
m_connectsocket.Create ( 0 ) ;
m_connectsocket.Connect ( m_server, m_port) ;
}

and the onaccept function is:
void CMultiAPIDlg::onaccept()
{
AfxMessageBox("Connected");

m_listensocket.Accept ( m_connectsocket ) ;
}

somehow, when the client connects to the server, the server dialog box will automatically close itself... can anyone help?


GeneralRe: Unable to create a server Pin
4apai26-Aug-04 2:25
4apai26-Aug-04 2:25 
GeneralRe: Unable to create a server Pin
Tom Wright26-Aug-04 6:41
Tom Wright26-Aug-04 6:41 
GeneralRe: Unable to create a server Pin
palbano26-Aug-04 8:36
palbano26-Aug-04 8:36 
GeneralRe: Unable to create a server Pin
Anonymous26-Aug-04 16:20
Anonymous26-Aug-04 16:20 
GeneralRe: Unable to create a server Pin
Anonymous26-Aug-04 17:04
Anonymous26-Aug-04 17:04 
GeneralRe: Unable to create a server Pin
palbano26-Aug-04 17:57
palbano26-Aug-04 17:57 
GeneralGet Token from SID Pin
4apai26-Aug-04 1:44
4apai26-Aug-04 1:44 
GeneralCLSID to char* Pin
anderslundsgard26-Aug-04 1:38
anderslundsgard26-Aug-04 1:38 
GeneralRe: CLSID to char* Pin
4apai26-Aug-04 1:48
4apai26-Aug-04 1:48 
GeneralRe: CLSID to char* Pin
anderslundsgard26-Aug-04 2:13
anderslundsgard26-Aug-04 2:13 
GeneralSave binary files in Access DB (ADO) Pin
Yaelinka26-Aug-04 1:37
Yaelinka26-Aug-04 1:37 
GeneralRe: Save binary files in Access DB (ADO) Pin
Scozturk26-Aug-04 1:53
professionalScozturk26-Aug-04 1:53 
GeneralRe: Save binary files in Access DB (ADO) Pin
Yaelinka26-Aug-04 1:55
Yaelinka26-Aug-04 1:55 
GeneralRe: Save binary files in Access DB (ADO) Pin
4apai26-Aug-04 2:11
4apai26-Aug-04 2:11 
GeneralRe: Save binary files in Access DB (ADO) Pin
Yaelinka26-Aug-04 2:18
Yaelinka26-Aug-04 2:18 
GeneralRe: Save binary files in Access DB (ADO) Pin
4apai26-Aug-04 2:35
4apai26-Aug-04 2:35 
GeneralRe: Save binary files in Access DB (ADO) Pin
Yaelinka26-Aug-04 3:56
Yaelinka26-Aug-04 3:56 

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.