Results 1 to 2 of 2

Thread: Rich Text Box's String Array

  1. #1

    Thread Starter
    KrisSiegel.com Kasracer's Avatar
    Join Date
    Jul 2003
    Location
    USA, Maryland
    Posts
    4,985

    Rich Text Box's String Array

    Using the properties window, you can edit the text within a text box using a string array. My question is... when the program is executed, is the data still stored in a string[]array? If so, how could I access that with code?

    Since each line is just another number in the array, it would be so easy to do many things I need to do.

    Thanks. BTW, sorry about the number of posts I've made, lol this is like my 3rd today and I got like 4 or 5 on the first page

  2. #2
    Frenzied Member dynamic_sysop's Avatar
    Join Date
    Jun 2003
    Location
    Ashby, Leicestershire.
    Posts
    1,142
    the string array is basically a collection of the lines , you can return a line by it's numer , eg:
    VB Code:
    1. Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
    2.         Dim x As Integer
    3.         For x = RichTextBox1.Lines.GetLowerBound(0) To RichTextBox1.Lines.GetUpperBound(0)
    4.             MessageBox.Show(RichTextBox1.Lines(x))
    5.         Next
    6.     End Sub
    ~
    if a post is resolved, please mark it as [Resolved]
    protected string get_Signature(){return Censored;}
    [vbcode][php] please use code tags when posting any code [/php][/vbcode]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width