i just want to know if it is possible to store the formatting of a text to ms sql so that the next time i retrieve a record that i've already formatted, it will display the format that i did for that record.if possible, how would i implement it in mssql?
Okay so I've got something, where when a button(Button1) is pressed, Text Appears in the RichTextBox When you press Button2, I want more text, in the same textbox, to be on a different line. I can get the text on the SAME line, but not a different one.
I am trying to change color of a selectedtext in Rich TextBox.When user check color radio button it should change the color of the selected text.I have 4 radio buttons inside groupbox.Can someone tell me how do i select text and change color.Below is my code but its not working as expected.[code]....
Basically I'm writing a little piece of photo-editing software and I would like the user to be able to write whatever they want as a caption for the photo. VB then writes that text in a blank space created under the picture. Pretty straightforward, I've got it printing the text and it can adjust for height differences (i.e. multiple lines of text, smaller fonts, etc.).
My issues arise in the horizontal direction, I cannot make the Richtextbox large enough to represent the width of the photos (Some pictures have dimensions several thousand pixels wide and most monitors cannot display that many...) so I have used horizontal scroll bars (wordwrap off) to allow the user to scroll across and see all the text. Now what I would like to do is to set a limit to how much text the user can enter on a line (based on pixels to accommodate for various fonts/sizes) and it seems to me that setting the .RightMargin to just a little less than the picture dimension (to allow for padding) should do just that. [Code]
I created a small Rectangle Shape that represents a specific color. How can I add it to a line in a RichTextbox?For example, the string would look like this: RectangleShape (represents department) + Department Name + Price etc.
I have an application that allows the user to define text in a rich textbox. I would like to give the user the ability to define text for one or more languages. I don't think this will be a problem using the rich textbox as it allows for unicode characters and DBCS (please let me know if this is incorrect). My question is, I display this text throughout the app in other controls as well, such as a listbox, label, etc. by acquiring the RTF's Text property (plain text). Are there problems with other controls displaying unicode/DBCS characters? I realize that I may have to toggle the font of the control in question depending on the language (I will allow the user to specify a default font per language).
I have a rich text box where you can edit java code with a listbox on the side of it that has the line numbers. I want the listbox to scroll with the rich text box so that they line up. How would you get them to scroll as one?
I'm using a Rich Textbox in my vb.net application on update form to take address value. My update query is generated at run time looping through the textboxes on the form and checking which fields have got some value and the corresponding fields are updated in the database. For Each x As Control In Me.Controls
It does indeed work. Then I have a button that makes the Rich Textbox not Visible. Using Richtextbox1.visible=False Then I have an open button, which makes it Visible again. But what I wanted is that the text inside the Rich Textbox to be color Black; but the color of the from the scroll keeps appearing. Here is my code for the Close Button:
I am trying to open up a text file that contains some text. I have 3 text boxes on my screen. What I need to figure out is how to replace multiple words (1 in each textbox) with text it finds in the txt file.
I can do this by using the single find / replace feature but I'm trying to be able to fill out the 3 textboxes and then click my find / replace button to have my Regex find each predefined word and replace it with what is in the text boxes.
Here is my code to get the find / replace one word at time feature. I've tinkered with this to just add more variables to my Regex but it doesn't seem to work.
I have 3 rich textboxes on my form and I need to extract the data from box 1 and box 2 and put it into box 3 without losing the formatting (as you know richtext boxes can support colour and picture formatting that i currently have in box 1 and 2). I tried the following but it strips all the formatting from box 1 and box 2.
I am using a Rich TextBox in VB.NET and passing to a StringBuilder. I need to replace the New Line character from the TextBox with either a space or a comma. Problem is the standard codes for new line don't seem to be picking up this New Line character in this case. Is there a specific character used in Rich TextBoxes as the New Line?
i am trying to figure out the code for a button for application where i take test from a richtextbox read it and change the color and font i have made the application for it, with 3 buttons. find, find next and replace.
I have looked around for awhile and have not seen anything yet. I was hoping someone came up with something by now that can guide me in the right direction. I have an rtf string pulled from my database. I was trying to find a way to display this rtf string formatted in silverlights richtextbox. From what I have read silverlights richtext stores formatted text as xaml and not true rtf. Has anyone found a work around?
I am adding characters to a RichTextBox one character at a time and setting the format of that character after it is added. The following code is a distillation of the actual code but reliably repeats the problem I am having.[code..]
While that is odd to me and unexpected, where it happens in the code is even stranger. By stepping through the code, prematurely going to the End Sub and then displaying the form, I was able to determine that when i = 3 and the line "Me.RichTextBox1.Text = Me.RichTextBox1.Text & "S" is exceuted, the color of the first two "S" are changed from Blue and Red to all BLUE.
I do not understand.a way to add characters to a RichtextBox and set the formatting of those characters?
This example is just color. I the real project I am setting Size, Color, Bold and Italics. I do not know if the solution to this color problem will affect the other formatting information.[code...]
How to display text in a rich text box when an item is selected in a listbox. Here's a snippet of my Private Sub radGunsNRoses_CheckedChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles radGunsNRoses.Click 'Declares songs into variables Dim strSong1 As String = "1. Sweet Child O' Mine" Dim strSong2 As String = "2. Novemeber Rain" Dim strSong3 As Integer = "3. Welcome to the Jungle" 'Band Picture [Code] .....
What I really want is that when radGunsNRoses is checked, the listbox displays the songs and when one is clicked, it shows the song's lyrics in the ritfSongs. Same thing goes for radACDC but the songs are different and the lyrics.
I have a rich textbox with words in it separated by space characters. I want to create a mouseover event so that when I drag the cursor over a single word in the rich textbox that the word wil be highlighted grey. How do I set up the mouse over event to trigger whilst hovering above this specific control and do I make it recognize a stand alone word,
I have a vb.net program that allows you to access webpages in my localhost. Now, my problem is that, when I try to list records in mysql by using tables, it remembers history and the previous data that you listed will appear like a ghost even if the data you inputted does not correspond to the data that it is showing. How can I avoid that?
I am trying to find the code that would be necessary in order to add a dash on a new line when pressing the ENTER key.[code]so it puts the dash but the cursor moves below the dash.Any ideas what I need to keep the cursor beside the dash?
I want to update some things on the form when the user clicks a new date (or changes the month, which automatically selects a new date). If I use the DateSelected event, it seems to work as expected when I use the mouse. However if the arrow keys are used, the event does not get triggered. If I use the DateChanged event, it seems to go into an infinite loop. The message box pops up a zillion times when I click the arrow to change the month:
Private Sub MonthCalendar1_DateChanged(ByVal sender As System.Object, ByVal e As System.Windows.Forms.DateRangeEventArgs) Handles MonthCalendar1.DateChanged MessageBox.Show("DateChanged")[code]....
The only problem with using the DateSelected event is that if the user uses the arrow keys, the event is not fired. I thought I could fix this by disallowing the use of the arrow keys, but I couldn't find anywhere to do that.