Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Strange 1

Status
Not open for further replies.

jimjake

Technical User
Oct 30, 2004
25
US
The below code is what I have put in to check the length
Of m_EditBox. Below that is the error I am getting. Does anyone know where
The A is coming from, I did not type it.

CString strEdit;
m_EditBox.GetWindowText (strEdit);
int nLen=strEdit.GetLength ();








error C2039: 'GetWindowTextA' : is not a member of 'CString'
c:\program files\microsoft visual studio\vc98\mfc\include\afx.h(368) : see declaration of 'CString'
Error executing cl.exe.
 
GetWindowTextA() is the function in the windows api that is called for GetWindowText() depending on whether or not you have _UNICODE defined. 'A' is for ASCII, I think. If you have UNICODE definied, it should be GetWindowTextW(). But it seems to be that the problem is that m_EditBox is declared as a CString variable instead of a CEdit variable. Check how it's declared.

BlackDice

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top