CString tabbing....

Hello again,
I have yet another question that I need answered.
I got a CString variable that I used the format property 
to set the text.  Here is what the code looks like....
FinalResult.Format("%s\t%s\t%s",TmpBfr,TmpBfr2,TmpBfr3);
When I print out this string I get an odd character, 
instead of a tab between the strings.  What can I do to 
get the output from the printer to have these tabs 
instead of the weird character?
Thanks in advance,
James Simpson
Straightway Technologies
0
anonymous (74722)
11/29/2003 10:37:10 AM
vc.mfc 33608 articles. 0 followers. Follow

3 Replies
278 Views

Similar Articles

[PageSpeed] 59

>I got a CString variable that I used the format property 
>to set the text.  Here is what the code looks like....
>FinalResult.Format("%s\t%s\t%s",TmpBfr,TmpBfr2,TmpBfr3);
>When I print out this string I get an odd character, 
>instead of a tab between the strings.

James,

You fail to tell us the key point - how are you outputting the string
to the printer?

If you're using TextOut, then it won't do any tab character expansion.
Have a look at using TabbedTextOut or DrawText instead.

Dave
-- 
MVP VC++ FAQ: http://www.mvps.org/vcfaq
0
davidl (422)
11/29/2003 3:23:16 PM
Yeah I am using TextOut using a device context (dc).

Sincerely,
James Simpson
Straightway Technologies
0
anonymous (74722)
11/30/2003 5:19:03 AM
>Yeah I am using TextOut using a device context (dc).

OK, so there's your problem :)

Dave
-- 
MVP VC++ FAQ: http://www.mvps.org/vcfaq
0
davidl (422)
11/30/2003 5:55:36 PM
Reply:

Similar Artilces:

How to set dynmically the Tab order in a Dialog
I want to set the Tab order of all controls inside dialog dynamically, using API's is it possible.Can any one tell me. "RAG" <raghavenderb@hcl.in> wrote in message news:1155725264.728076.54870@74g2000cwt.googlegroups.com... >I want to set the Tab order of all controls inside dialog dynamically, > using API's is it possible.Can any one tell me. Well they're originally in the order of your AddPage calls to the property sheet. Do you mean that you want to reset the order? I have never done that but I have used CPropertySheet::AddPage and RemovePage (...

How do I change the default "file origin" when opening a tab delimited text file?
Excel2002 /Win2K Hi When I save a spreadsheet to tab delimited text and re-open it (and this is something I do a *lot* to get rid of micro$oft formatting and stray HTML coding...) it always defaults the "file origin" to be "932:Japanese (Shift-JIS)" instead of "1252:Western European (Windows)"! How do I get my MS Excel to default to the correct thing?! ie I want it to default to: "1252:Western European (Windows)" and not "932:Japanese (Shift-JIS)" whenever I open a .txt file ! Ship Shiperton Henethe ...

CString LoadString return "an unnamed file"
Greetings. I have this problem when I call LoadString on a CString object, I'm getting "an unnamed file". It is very likely that me, or someone close to me :-) , have edited the resource file. Anybody knows how to fix this problem? I can add dialogs and toolbar buttons but I can't edit the status bar messages or add string resources to load. Thanks in advance. John. Which version of VS are you using. Could it be that your .rc file got changed into Unicode somehow. The older versions of VS didn't handle that well. Could also be that something is goofed up in t...

How do I link the title on my tab(below) to a cell
I'd like the title of my worksheet to correspond with a certain cell. Rather than specifying a report title, you could enter is as a heading above the cell in question. -- Regards, Fred Please reply to newsgroup, not e-mail "Goose" <Goose@discussions.microsoft.com> wrote in message news:5AF912C1-1CC5-45AF-BFDD-D2BDF7B4B957@microsoft.com... > I'd like the title of my worksheet to correspond with a certain cell. ...

Using atl based win dll with CString functions from the mfc projec
I have atl based general windows dll with class which contains functions which uses CString as parameters or return values. This dll might be used from the atl or mfc project. Dll can be used from ATL project without problems but whenever I try to use this class from the MFC project I get the following linker errors: error LNK2019: unresolved external symbol "__declspec(dllimport) public: int __thiscall MyClass::AddMenu(long,class ATL::CStringT<wchar_t,class StrTraitMFC_DLL<wchar_t,class ATL::ChTraitsCRT<wchar_t> > > const &,long)" ... If I replace CStri...

Name a worksheet tab based on the value in a cell.
Hello all, I have found a lot of posts about how to populate a cell with the value in the worksheet tab name, but not the other way around. I would like to automatically name the worksheet tab based on the value in a specific cell. I'm ok with formula's but not "up" on VB. Is there a formula I could use to accomplish this? Thanks in advance for any help you can give me. Christine Hi Christine, A formula cannot name a worksheet, VBA would be required. For example: Code: -------------------- Sub nameSheet() ActiveSheet.Name = Acti...

Make custom tabs and fields available to mail merge
We have created custom tabs and fields specific to our business and need to pull from those when doing a mail merge. Right now only "built in" fields are available. We are using Microsoft CRM 1.2. With Microsoft CRM this is with the mailmerge functionality not possible! But for this we made a Add-On for MS CRM. WordMailMerge for Microsoft CRM 1.2 addresses exactly that problem. You can download a trial version at www.mscrm-addons.com. -- -- Christian support@mscrm-addons.com www.mscrm-addons.com Your company for MS-CRM ADD-ONS! GroupCalendar for MSCRM Rela...

Publishing page tabs
Hi all, I have a visio file with numerous pages that I want to publish. Instead of having the navigation panel on the left side to move between pages, I would like to keep the tabs at the bottom of the page that are used in the actual visio file. Anyway to do this? Every time I publish the file, the tabs disappear and instead I end up with the left side navigation panel. Thanks in advance, Tim You could use the Visio Viewer to do this (no publishing required), or will have to write your own web page code to provide the page tabs. "tim500" <tim500@discussions.microsoft....

How to copy data from certain cell in one tab to another tab
I am wanting to set up a worksheet so a user can click a check box (or whatever the best method would be) and copy that row to another worksheet in the workbook (or another workbook) in the next cell down each time it is checked. i.e. ()A B C 1 2 3 checking the box would copy 1 2 3 to the worksheet/workbook of choice in the next empty row. Thanks Sorry that should be: A B C ()1 2 3 Thanks One method.........double-click event code on any cell in the row. Private Sub Worksheet_BeforeDoubleClick(ByVal Target _ ...

Security tab missing
Does anyone remember what the registry change is to display the security tab on the Exchange user? I want to go in and give different users receive as and send as rights, and I need access to the security tab? Any ideas? Is this a client side or server side change? Thanks in advance! -DC is this what you're looking for? http://support.microsoft.com/default.aspx?scid=kb;en-us;264733 "DC" <anonymous@discussions.microsoft.com> wrote in message news:1d7601c4272d$ece293a0$a101280a@phx.gbl... > Does anyone remember what the registry change is to > display the s...

email address tab missing from Public Folder properties
When I create a new Public Folder, I don't see the email address tab in the properties panel. Existing folders show General Replication Limits Exchange General E-mail Addresses Exchange Advanced Details Permissions Member Of but new folders only show General Replication Limits Details Permissions How do I fix this? Thanks! -- Jim "Jim Elden" <x@yz> wrote: >When I create a new Public Folder, I don't see the email address tab in the >properties panel. Existing folders show > >General >Replication >Limits >Exchange General >E-mail Addres...

No "Permissions" Tab in Mailbox settings for one of my Outlook 2000 users HELP
I cant get a Permissions tab to show up on any Inbox, Mailbox, Sent Items, etc properties page like my other Exchange users. Why is it missing? What must I do to gain access to the Permissions tab? Am I missing something obvious? The users configs appear to be identical as other machines. Thanks for your guidance, I searched the groups and couldn't find anyone else with the same problem. -Brendan Is this specific to one installation of Outlook, or for one particular mailbox regardless of which Outlook you use to open it, or what? -- Ed Crowley MVP - Exchange "Protecting the wor...

Help does not allow entry in Answer Wizard or Index tab
Hello -- I am using Office 2000 Pro; Excel version is 9.0.6976 SP-3.. If I click a word in VBA, Help displays a help screen about it. However, the top menu bar says "Microsoft Access Help". I have Access on the machine. And, if I click the Answer Wizard or Index tab, the shape of the cursor in any field changes to a horizontal, double-ended arrow. Can anyone tell he how to solve this problem? Thanks for any help. L Mehl --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.572 / Virus Database: 362 - Release Da...

Permissions tab missing from Inbox properties
Hello, When attempting to view the properties for a user's Inbox or any folder/subfolder in their mailbox the permissions tab is missing (this is occuring while I'm logged on his workstation as the user). Yet when I open outlook on another workstation logged in as administrator and add the user's mailbox to the outlook profile I can see the permissions tab. I checked permissions on the Exchange server and I even added his account as owner to his mailbox but the issued persisted. Enviroment: Windows 2000 Small Buiness Enterprise server SP4 Windows 2000 Pro SP4 with Outlook...

emailing just one worksheet/tab of workbook
Is it possible to send only one worksheet/tab in an e-mail or is the entire workbook the only option? Our school district is using Excel 2007 and our secretary would like to be able to send only certain worksheets to teachers. In article <053e56bd-0f01-4ebf-8a98-deb93c3cbdbe@z66g2000hsc.googlegroups.com>, Michelle <teacher24_70@yahoo.com> wrote: >Is it possible to send only one worksheet/tab in an e-mail or is the >entire workbook the only option? Our school district is using Excel >2007 and our secretary would like to be able to send only certain >worksheets to teac...

Adding a field on a new tab
For accounts: I have added a new tab, where I want to be able to choose in which business segments we potential. However there are no fields available for this in the database. How do I do to add additional fields? I would like to have the configured similar to how the contact methods are formatted with radiobuttons (Allow / do not allow). For contactpersons I have added a tab for courseregistrations. I want to use this when someone registers for a seminar. Same as above. However I want to delete old records, is there a risk if I delete datavalues if some contacts have values in these ...

Put photo on the tabcontrol's 1st tab
Hello, The first tab of my tabconrol is genereal information. I have a form to input the data of photo which is to input the imagepath and I have tested it runs ok. The primary key of my member table is Autonumber and I linked it with my image tabtle with the same name of the field in order to autofill the primary key of the image table ( the relationship is one to one then). My problem when I put this form as a subform in genereal infromation, it does not work. The member sequence number becomes auto number, while on the form itself I have already put the number, the same as number i...

In Excel can sheet tabs be placed along a side margin?
Instead of having tables along the bottom of a sheet, I want to put them down the right hand margin. Is this possible in Excel? SuzieQ, Nope, you can't do that. Mike "SuzieQ" wrote: > Instead of having tables along the bottom of a sheet, I want to put them down > the right hand margin. Is this possible in Excel? ...

how do i change paper size for multiple tabs in Visio?
Hello, was wondering if anyone knows how to change the paper size for a Visio file containing multiple drawings. For example, in Excel, you can hit "control" and select all tabs at once to change the settings for all the tabs. Please let me know if there is something similar in Visio--right now I can only figure out how to change the setting one "tab" at a time. You can only change one tab at a time. -- John... Visio MVP Need stencils or ideas? http://www.mvps.org/visio/3rdparty.htm Need VBA examples? http://www.mvps.org/visio/VBA.htm Common Visio Questions h...

Tab color?
When I set Tab Color, it only puts an underscore of the selected color under the sheet name. I would like to change the background color of the tab -- ideally even the font style and color of the tab name. Can any of that be done? I suspect not because when I do Record Macro while renaming a tab and changing tab color, the normally VBA code is uncharacteristically succinct, revealing nothing more being done than I can already see, setting only .Name and .Tab.ColorIndex. If the sheet is active the color is shown only as an underscore. Inactive sheets show the full tab...

Set Focus on tabs
i have a tab control w/ a bunch of tabs. most of these tabs have subform (or 2). to increase performance, the subforms are unbound until the tab is clicked (i do this w/ code). this works well. the issue is when i click on one of the tabs w/ a subform, i can NOT use the Tab key; i get a Windows 'beep' (no error message). it is as if there is NO focus on any control. if i click in a subform/control on that tab, i can then use the Tab key to navigate. this is annoying as it slows down data entry because i then have to use the mouse. this does NOT happen if: i remove the code that sets ...

Tab character in a multiline text edit field?
Hi! This is probably a stupid, question, but: When creating a dialog with a multiline text edit field, I am unable to make the field insert the tab character when I press the tab key, it only selects all text. Or rather, it wants to go to the next control, but as the edit field is the only control... well, you know what I mean. This should be a normal text-file editor. What to do about this? Hoping for a quick response, Morten "Morten Aune Lyrstad" <too@much.spam> wrote in message news:qqkGc.61$GY2.13412@juliett.dax.net... > Hi! This is probably a stupid, question, but: ...

RMS Store Ops should have a Related Items Tab in Item properties
RMS Store Ops 1.3 There should be a tab in item properties to set-up related items. This would be very useful if you're using software, like Nitrosell, to sync RMS with your webstore. ---------------- This post is a suggestion for Microsoft, and Microsoft responds to the suggestions with the most votes. To vote for this suggestion, click the "I Agree" button in the message pane. If you do not see the button, follow this link to open the suggestion in the Microsoft Web-based Newsreader and then click "I Agree" in the message pane. http://www.microsoft.com/Busine...

Help Please With Tab Delimited files.......excel 2003
Okay i pretty new to Excel (office version 2003) , i need to make and save some tab delimited files , No probs , but when i load them back up , for example a long number such as :- 5031366015174 saves okay and is fine in its delimited text file , but when i load the tab delimited file back into excel the long number has become 5.03137E+12 , so when i save it again after adding more data to the list , the number is no long any use ?!?! any way to stop this please. When i load the file back into excel i choose delimited , file origin ms-dos(pc-8), delimiter tab,column data general , all ...

IE8 gives"stopped working" message when I close tabs
I've seen a lot of people complaining about this but no fixes. When I close an open explorer window, I get a message that IE has stopped working and it is searching for a fix, then a box to close the program. So far, I have reset all the defaults for IE8 and tried using IE without any add-ons. It works correctly without add-ons. The only changes to the computer in the last few days have been: download a driver scanner which installed the Ask add-on, updated something from Adobe, and the automatic Windows update ran. Any ideas where the problem came from? -- Win 7, IE8, Fu...