Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

clear text boxs in vb programming

Posted on 2012-03-10
6
Medium Priority
?
179 Views
Last Modified: 2012-06-21
I am currently working on a program and I want to make it where the output text box clears every time there is a change in the input text box how can I do this?
0
Comment
Question by:afeistel2
  • 3
5 Comments
 
LVL 86

Accepted Solution

by:
Mike Tomlinson earned 2000 total points
ID: 37705646
What is your environment here?  VBA, VB6, VB.Net?...

Here's a simple VB.Net example:
    Private Sub txtInput_TextChanged(sender As System.Object, e As System.EventArgs) Handles txtInput.TextChanged
        txtOutput.Clear()
    End Sub

Open in new window

0
 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 37705651
Here's a VBA/VB6 example:
Private Sub txtInput_Change()
    txtOutput.Text = ""
End Sub

Open in new window

0
 

Author Comment

by:afeistel2
ID: 37705778
I'm using vb 2010 Express.
0
 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 37705799
Then the first example should be helpful.  It requires two TextBoxes, one called "txtInput" and the other called "txtOutput".  Just place that code into the form.
0
 
LVL 49

Expert Comment

by:Martin Liss
ID: 37820874
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses

877 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question