Computing.Net > Forums > Programming > EVC++: line break problem in edit b

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Click here to start participating now! Also, check out the New User Guide.

EVC++: line break problem in edit b

Reply to Message Icon

Name: bluebeta
Date: May 10, 2006 at 23:32:15 Pacific
OS: WinCE 4.2
CPU/Ram: emulator
Product: Ms. Windows
Comment:

Hi,

I am using ECC++ 4.0 and WinCE 4.2 emulator, I have create a unicode text file and the file contents is as below:
file content:
-----------
Testing123
Test456
Test789

I read the contents of the file and display in the multiline edit box. The result is as below:

Testing123□Test456□Test789□

But this is not the result that I expect, how should I display in edit box as below:

Testing123
Test456
Test789

I had tried to use AfxMessageBox() to display the result and it give me the correct result.

Below is my code:
================================================== =======

CStudioFile f;
CString s;
char asciibuff[4096];

m_sListSerial = _T("");
if (f.Open(L"serialno.txt", CFile::modeRead | CFile::shareExclusive | CFile::typeText))
{
while(f.ReadString(s,true))
{
m_sListSerial += s;
}
f.Close();

AfxMessageBox(m_sListSerial);
WideCharToMultiByte(CP_ACP, 0, m_sListSerial, -1, asciibuff, 4096, NULL, NULL);

m_sSerialNo = asciibuff;
UpdateData (FALSE);
}

================================================== =======

Can someome please help. Thanks in advance.

Best Regards.



Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More


answering machine applica... Delphi 5 -Advice desperat...



Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Sponsored links

Ads by Google


Results for: EVC++: line break problem in edit b

file problem in qbasic www.computing.net/answers/programming/file-problem-in-qbasic/10524.html

script to insert a line break www.computing.net/answers/programming/script-to-insert-a-line-break/9499.html

Send email w/o extra line breaks www.computing.net/answers/programming/send-email-wo-extra-line-breaks/14779.html