Edit Ctrl ( May be easy but... )

I NEED to use SetWindowText to put text in my
Edit/RichEdit Ctrl… ( ATL created subclassed from
Edit )----------------
I am using SetWindowText every time the user is
typing into the Edit Ctrl bcz ( I may be changing to
different font etc ).
The problem i am facing is that after one line
is complete my edit box displays the last characters
on the first line and brings the first ones on the
second line and so on… I tried to put a carraige
return and line feed in my string to SetWindowText but
it continues with the same problem with displaying
strange characters for the carriage return & line feed
i am giving in the string … ( I am using \r and \n
)…
I cannot find anywhere whether i will have to
select some style for that EditCtrl or … some other
way around


Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

If you have set wordwrap for your Edit Ctrl (EM_FMTLINES), a soft line break
consists of two carriage returns and a linefeed is inserted at the end of a
line that is broken. Turn wordwrapping off, maybe it helps.

Use \x0d\x0a not \n (for one byte char. set of course). \n should add
carriage return and linefeed to Edit control, but it adds only \0x0a.

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com]On Behalf Of irfan bashir
Sent: Dienstag, 7. August 2001 09:14
To: NT Developers Interest List
Subject: [ntdev] Edit Ctrl ( May be easy but… )

I NEED to use SetWindowText to put text in my
Edit/RichEdit Ctrl… ( ATL created subclassed from
Edit )----------------
I am using SetWindowText every time the user is
typing into the Edit Ctrl bcz ( I may be changing to
different font etc ).
The problem i am facing is that after one line
is complete my edit box displays the last characters
on the first line and brings the first ones on the
second line and so on… I tried to put a carraige
return and line feed in my string to SetWindowText but
it continues with the same problem with displaying
strange characters for the carriage return & line feed
i am giving in the string … ( I am using \r and \n
)…
I cannot find anywhere whether i will have to
select some style for that EditCtrl or … some other
way around


Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/


You are currently subscribed to ntdev as: xxxxx@pmns.de
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com