PC Review Forums Newsgroups Microsoft DotNet Microsoft Dot NET Framework Forms rtf problem - nonbreaking hyphen breaks plus other problems

Reply

rtf problem - nonbreaking hyphen breaks plus other problems

 
Thread Tools Rate Thread
Old 01-06-2005, 05:10 PM   #1
=?Utf-8?B?dHNpR2Vvcmdl?=
Guest
 
Posts: n/a
Default rtf problem - nonbreaking hyphen breaks plus other problems


I'm using a read only rich text box to format some text. In the text is a
series of phone numbers separated by a comma and a space. I don't want the
phone numbers to be split. Here's what I've done. I replace "-" with "\_"
which is supposed to be the non-breaking hyphen. If I look at the string
before it is stored in the rtf it looks like "555\_201\_1234, 555\_201\_1111,
". In the rtf it looks like "555-201-1234, 555-201-1111, ". When the form is
displayed at the normal size the series of phone numbers are displayed
correctly except that the space after the comma is at the beginning of the
next line. When the form is made larger the scroll bar is removed and the
series of phone numbers split on one the hyphens and the space after the
comma ends up at the beginning of the line screwing up the format. Only the
scroll bar When the form is restored to it's original size the scroll bar is
missing until you set the cursor in the rtf box and move the cursor down.
--
tsiGeorge
  Reply With Quote
Old 01-06-2005, 06:12 PM   #2
Pete
Guest
 
Posts: n/a
Default Re: rtf problem - nonbreaking hyphen breaks plus other problems


A bit confusing to read: try using paragraphs next time so the problem is easier to grasp.

Ok, we have an example of the input numbers. Pls give a clean example of the intended output.

I am not sure the issue with the scroll bar, but lets deal with the formatting first...

/Pete.


"tsiGeorge" <molly@community.nospam> wrote in message
news:B814729D-4F9B-4079-BD4A-CA94866EA410@microsoft.com...
| I'm using a read only rich text box to format some text. In the text is a
| series of phone numbers separated by a comma and a space. I don't want the
| phone numbers to be split. Here's what I've done. I replace "-" with "\_"
| which is supposed to be the non-breaking hyphen. If I look at the string
| before it is stored in the rtf it looks like "555\_201\_1234, 555\_201\_1111,
| ". In the rtf it looks like "555-201-1234, 555-201-1111, ". When the form is
| displayed at the normal size the series of phone numbers are displayed
| correctly except that the space after the comma is at the beginning of the
| next line. When the form is made larger the scroll bar is removed and the
| series of phone numbers split on one the hyphens and the space after the
| comma ends up at the beginning of the line screwing up the format. Only the
| scroll bar When the form is restored to it's original size the scroll bar is
| missing until you set the cursor in the rtf box and move the cursor down.
| --
| tsiGeorge

  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off