Results 1 to 8 of 8

Thread: Textbox to Titlebar ????

  1. #1

    Thread Starter
    Member
    Join Date
    May 2004
    Posts
    36

    Textbox to Titlebar ????

    Ok I'm creating a program that requires customer info entry and what I would like to do if possible, I've seen it before, is when you type the name of the customer, that it also apear in the titlebar.

    The textboxes are as follows:

    First Name
    Middle Initial
    Last Name

    Thanks in advance

    Brad Nichols

  2. #2
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170
    VB Code:
    1. Me.Text = TextBox1.Text

  3. #3
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170
    Or you could just use a combination of the textboxes, however you want:

    VB Code:
    1. Me.Text = TextBox1.Text & " " & TextBox2.Text & " " & TextBox3.Text

  4. #4

    Thread Starter
    Member
    Join Date
    May 2004
    Posts
    36
    Yes but how do I get it to update in Real-Time? i.e. as I fill in the textboxes.

  5. #5
    New Member
    Join Date
    May 2004
    Location
    Dubai
    Posts
    5
    Put the statement:

    Me.Text = TextBox1.Text & " " & TextBox2.Text & " " & TextBox3.Text

    to the TextChanged event of each of the textboxes.

  6. #6

    Thread Starter
    Member
    Join Date
    May 2004
    Posts
    36
    give me an example of what the code would look like

    the placement has got me

    Sorry

  7. #7
    New Member
    Join Date
    May 2004
    Location
    Dubai
    Posts
    5
    Private Sub TextBox1_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox1.TextChanged
    Me.Text = TextBox1.Text & " " & TextBox2.Text & " " & TextBox3.Text
    End Sub

    Private Sub TextBox2_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox2.TextChanged
    Me.Text = TextBox1.Text & " " & TextBox2.Text & " " & TextBox3.Text
    End Sub

    Private Sub TextBox3_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox3.TextChanged
    Me.Text = TextBox1.Text & " " & TextBox2.Text & " " & TextBox3.Text
    End Sub

  8. #8

    Thread Starter
    Member
    Join Date
    May 2004
    Posts
    36
    Now I understand thanks!

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