Go Back  Xtreme Visual Basic Talk > Visual Basic .NET (2002/2003/2005/2008, including Express editions) > .NET General > textbox+button+mouse problem


Reply
 
Thread Tools Display Modes
  #1  
Old 07-23-2012, 02:37 AM
chenaz chenaz is offline
Newcomer
 
Join Date: Jul 2012
Posts: 1
Default textbox+button+mouse problem


http://img338.imageshack.us/img338/3871/keyboardc.jpg

http://img204.imageshack.us/img204/7607/addp.jpg

i created this 2 form,
i wan the selected textbox to capture the button text when user click on it. but i cant get it done. anyone can help me pls?
Reply With Quote
  #2  
Old 07-23-2012, 12:17 PM
Fat_Lip's Avatar
Fat_Lip Fat_Lip is offline
Centurion
 
Join Date: Feb 2005
Posts: 113
Default

This might be what you are looking for...

Code:
Public Class Form1

    Private str As String

    Private Sub btnA_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnA.Click
        str = TextBox1.Text & "a"
        TextBox1.Text = str
    End Sub

    Private Sub btnB_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnB.Click
        str = TextBox1.Text & "b"
        TextBox1.Text = str
    End Sub

    Private Sub btnC_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnC.Click
        str = TextBox1.Text & "c"
        TextBox1.Text = str
    End Sub

End Class
Attached Images
File Type: jpg Untitled-2.jpg (20.5 KB, 5 views)
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Advertisement:





Free Publications
The ASP.NET 2.0 Anthology
101 Essential Tips, Tricks & Hacks - Free 156 Page Preview. Learn the most practical features and best approaches for ASP.NET.
subscribe
Programmers Heaven C# School Book -Free 338 Page eBook
The Programmers Heaven C# School book covers the .NET framework and the C# language.
subscribe
Build Your Own ASP.NET 3.5 Web Site Using C# & VB, 3rd Edition - Free 219 Page Preview!
This comprehensive step-by-step guide will help get your database-driven ASP.NET web site up and running in no time..
subscribe
 
 
-->