Refreshing Richtextbox??

If you need help with a project or need to know how to do something specific in VB.NET then please ask your questions in here.
Forum rules
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.
5 posts Page 1 of 1
Contributors
User avatar
hungryhounduk
VIP - Site Partner
VIP - Site Partner
Posts: 2870
Joined: Mon Jul 27, 2009 11:58 am

Refreshing Richtextbox??
hungryhounduk
Hey Peeps

Long time me no see :)

I wonder if anyone can help me with a little problem i am encountering with an app i am making..

I have a Richtextbox which accepts text Input from a Textbox and i have the option to add images to the richtextbox as well as the text...

When i refresh the Richtextbox when testing the app and have text and image showing, it only refreshes the text and leaves out the Image? :shock:

So my question is = how can I refresh the Richtextbox and keep the Text and Image intact?

Any help will be most gratefull and i will reward those with credits for help (that works) :)

cheers

Chris
Image
User avatar
comathi
Coding God
Coding God
Posts: 1242
Joined: Fri Mar 26, 2010 1:59 pm

Re: Refreshing Richtextbox??
comathi
What do you use to refresh the TextBox? Is it simply Textbox.text=... ?
User avatar
hungryhounduk
VIP - Site Partner
VIP - Site Partner
Posts: 2870
Joined: Mon Jul 27, 2009 11:58 am

Re: Refreshing Richtextbox??
hungryhounduk
Hey Comathi
What do you use to refresh the TextBox? Is it simply Textbox.text=... ?
Code: Select all
"Name:  " & TextBox1.Text & "    " & vbCrLf & vbCrLf & _
That code above refreshes the textboxes in the the richtextbox

But the code i am using to refresh the page when the image and text in present is
Code: Select all
Richtextbox1.refresh()
Chris
Image
User avatar
comathi
Coding God
Coding God
Posts: 1242
Joined: Fri Mar 26, 2010 1:59 pm

Re: Refreshing Richtextbox??
comathi
If you're familiar with C#, this might help you: http://www.codeproject.com/Articles/454 ... xtBox-at-R

It explains how to insert both text and images programatically into a RichTextBox control.
User avatar
Scottie1972
Codenstuff Elite
Codenstuff Elite
Posts: 953
Joined: Thu Jan 14, 2010 5:48 am

Re: Refreshing Richtextbox??
Scottie1972
copy the text and image in the richtextbox control. as in copy and paste that way you will have a copy of the richtextbox.
just copy it to memory then at refresh() paste it back.
idk? it might work
Image
5 posts Page 1 of 1
Return to “Coding Help & Support”