Display in graphical interfaces when using callback or IceStorm

in Help Center
Hello,
My server get file form remote, and my client get state when the server getting files. I shoud use callback mechanism or IceStorm putting message from server to client. My ice like:
module Demo{
interface msgCallback{
void transferred(string message);
};
interface getFileStorm{
void bcstMessage(string message);
};
interface myComm{
bool getFile(string filename, msgCallback* cb);
};
};
In the client, my callback definition like:
class CallbackReceiverI : public msgCallback
{
void transferred(const string& message, const Ice::Current& cur)
{
TRACE("%s\n", message.c_str()); // OK
c_pDlg.strMsg = message; // a global pointer to a dialog
c_pDlg.UpdateData(FALSE); // fail
}
};
The subscribe side definition like:
class MyStormI : public getFileStorm{
virtual void bcstMessage(const string& message, const Ice::Current& cur)
{
TRACE("%s\n", message.c_str());
c_pDlg.strMsg = message;
c_pDlg.UpdateData(FALSE);
}
};
The messages display in console OK, but fail in graphical interfaces. The error message in the attach files. How could this be? What can I do. Help me. Thank you.
My server get file form remote, and my client get state when the server getting files. I shoud use callback mechanism or IceStorm putting message from server to client. My ice like:
module Demo{
interface msgCallback{
void transferred(string message);
};
interface getFileStorm{
void bcstMessage(string message);
};
interface myComm{
bool getFile(string filename, msgCallback* cb);
};
};
In the client, my callback definition like:
class CallbackReceiverI : public msgCallback
{
void transferred(const string& message, const Ice::Current& cur)
{
TRACE("%s\n", message.c_str()); // OK
c_pDlg.strMsg = message; // a global pointer to a dialog
c_pDlg.UpdateData(FALSE); // fail
}
};
The subscribe side definition like:
class MyStormI : public getFileStorm{
virtual void bcstMessage(const string& message, const Ice::Current& cur)
{
TRACE("%s\n", message.c_str());
c_pDlg.strMsg = message;
c_pDlg.UpdateData(FALSE);
}
};
The messages display in console OK, but fail in graphical interfaces. The error message in the attach files. How could this be? What can I do. Help me. Thank you.
0
Comments