steev Posted November 30, 2006 Share Posted November 30, 2006 I'm new to Visual basic and going through a set of beginner tutorials.I've made a form with textboxes.Question: When I scroll through all the textboxes and return to the first one - how do I write the code to say "clear the box and make it empty"I think it's an If..else statement but after days of frustration and searching online, I still can't find the answer!!Regards,Steve Link to comment Share on other sites More sharing options...
ColdFusion200 Posted December 5, 2006 Share Posted December 5, 2006 txtBox.Text = "" Link to comment Share on other sites More sharing options...
neo Posted December 5, 2006 Share Posted December 5, 2006 (edited) slect text box and see the propertiesIn VB 6.0 remove existing text from Caption property.In VB2005 remove exsiting text from Text property. Edited December 6, 2006 by neo_matrix.rs Link to comment Share on other sites More sharing options...
IcemanND Posted December 5, 2006 Share Posted December 5, 2006 In VB6 caption is for a label not a textbox. There is no caption property for a textbox. textbox.text="" like ColdFusion said should work for any VB textbox. Link to comment Share on other sites More sharing options...
neo Posted December 6, 2006 Share Posted December 6, 2006 Sorry..! I have made mistake... Link to comment Share on other sites More sharing options...
steev Posted December 12, 2006 Author Share Posted December 12, 2006 Thanks for your help - that works!!Regards,Steve Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now