473,326 Members | 2,813 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

RichTextBox: problems inserting (c), TM and (R) symbols

I am trying to insert special characters into text of a
rich text edit box. The user should be able to press a
toolbarbutton to insert a specific character.
I have looked up RTF codes for (c) and (R) etc. and tried
the following code:

richTextBox1.SelectedRtf = @"{\rtf1\ansi \'99}";

This properly inserts a "TM" symbol in the text.

However, to my surprise, the box seems "screwed" after
this. I can edit the text that was there before the
insert, but not delete or overwrite the TM symbol. The
same applies to (c) and other symbols.

I also tried

richTextBox1.Rtf = @"{\rtf1 Some Symbol\'99}";

which results in a RTF box that cannot be edited any
more, but

richTextBox1.Rtf = @"{\rtf1 Some Text}";
works fine.

What's wrong here??
Jul 19 '05 #1
0 3567

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Juan | last post by:
I`m inserting strings in a rich text control using the AppendText method, I would like to change certain parts of the string so, for example, a certain word appears bold and red when inserted. Is...
1
by: gabe | last post by:
I am looking for a way to mimic some of the functionality of a web page without writing html (or I am looking to someone to point out something really obvious that I am over looking) Currently I...
2
by: Clark Stevens | last post by:
Hi. This should be so easy, but I don't get it. Let say I have RichTextbox1 and I want to insert some text at the current insertion point, or at the beginning of selected text (if there is any). ...
8
by: Dennis | last post by:
How can I tell if the Insert Mode is on or off? -- Dennis in Houston
0
by: yuraukar | last post by:
I am trying to insert special characters into text of a rich text edit box. The user should be able to press a toolbarbutton to insert a specific character. I have looked up RTF codes for (c) and...
0
by: Boni | last post by:
Dear all, my Richtextbox.text contains tabs and may be other special symbols (\r\n). I need to set a cursor on a position after a charachter number X. But Richtextbox.selectionstart=X don't do it,...
0
by: ajithmanmadhan | last post by:
hi pls help me out in inserting text into a richtextbox. the situation is like this:: i want to insert a string say "hello" at a particular location in the rich textbox. The particular...
1
by: txomin | last post by:
Hi all, Following the instructions of this link http://support.microsoft.com/kb/812425, i've been able to print the content of a RichTextBox control . Apart from that , I want to have the chance...
1
by: IMAFriend | last post by:
So, if I have 2 richtextboxes, call them rtbSource and rtbTarget. I can say rtbTarget.rtf = rtbSource.rtf and it works. But if rtbTarget already has something in it, how can I 'insert' the...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.