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 Andrzejek on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to get tab character (\t) to work in MFC? 1

Status
Not open for further replies.

Rmck87

Programmer
Jul 14, 2003
182
US
Ok, so I have been trying to get a tab in a CString of an edit control, but no matter what method I use, I get the little square character that appears instead. What's going on? How do I get a tab?

Of course I have tried using \t in my CString, and I have tried other things as well. I have searched all over tek-tips and the web as well as MSDN but I cannot find anyone with this same problem. Is this just me?

Any help would be great! Thanks!

- Ryan

One Ring to Rule Them All, One Ring to Find Them, One Ring to Bring Them All, and in the Darkness Bind Them.
 
The control has to be setup to handle the tab character. I don't know if there is a specific setting for it, but all my multi-line edit controls show the tab properly and all the single line controls show the square character.
 
Wow! I never even thought of that. There is actually a specific setting on the control itself, called "Use Tabstops". It works, Thanks!

One Ring to Rule Them All, One Ring to Find Them, One Ring to Bring Them All, and in the Darkness Bind Them.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top