OnBnClicked funcion

Hello

I'm trying to make simple application from Visual C++ book
problem is that examples are for version 6 and I'm using Version 2005
so there are a lot of changes but most of the basic one I figure out

Ok, then I'm trying to make app (or funcion) that is taking text from edit box
and after clicking button it will display this message in new window should be simple but I'm gettin error error C2065: 'Lm_strWiadomosc' : undeclared identifier , here is my code :

Dialog box:

BOOL CAplikacjaDemoDlg::OnInitDialog()
{
CDialog::OnInitDialog();

SetIcon(m_hIcon, TRUE);
SetIcon(m_hIcon, FALSE);


m_strWiadomosc = "Enter text here" ;
m_bUdostepnijMW = TRUE;
m_bUdostepnijMP = TRUE;
m_bPokazMW = TRUE;
m_bPokazMP = TRUE;

UpdateData(FALSE);

return TRUE;

and here is button event:

void CAplikacjaDemoDlg::OnBnClickedWtlwsc()
{

UpdateData(TRUE);
MessageBox(_T(m_strWiadomosc));
}

this is just a part of this application so maybe problem is somwhere else
give me some hints

Regards
Sorry guys figure it out for those that have similar problem


MessageBox should be:
MessageBox (m_strWiadomosc); without _T

See you
Topic archived. No new replies allowed.