Go4Expert

Go4Expert (http://www.go4expert.com/)
-   MFC (http://www.go4expert.com/forums/mfc/)
-   -   Problem with SetWindowText / setDlgItemText??? (http://www.go4expert.com/forums/setwindowtext-setdlgitemtext-t9630/)

rajeswaridvssnr 28Mar2008 16:37

Problem with SetWindowText / setDlgItemText???
 
I was stuck up in small issue to show a text.........

I have tried all these alternatives....

m_text.SetWindowText(szMsg);//m_text is edit control variable

GetDlgItem(IDC_TEXT)->SetWindowText(szMsg)

SetDlgItemText(IDC_TEXT,szMsg);
m_text.SendMessage(WM_SETTEXT,NULL,(LPARAM)szMsg);

Why SetDlgItemText, SetWindowText, SendMessage not working/not setting the text properly....


I have a loop i need to show the text szMsg(like x of n files completed....) and i am calling another application in that loop using shellexecute which runs for 2 mins...and continues the loop....

for the 2 rounds it is changing the text correctly for the 3rd round onwards it is not changing it...when i was testing in the debug it is changing the szMsg correctly....what do i need to do here...??any solutions!!!! I have tried sleep also.....


All times are GMT +5.5. The time now is 07:54.