stewarts Posted April 8, 2003 Posted April 8, 2003 Visual Basic .NET.... I have a textbox on my form whose text property is bound to a datasource. If I set the Visible property to FALSE, I can no longer see the textbox.text value in my code. When the Visible property is set to TRUE, no problem. Any ideas??? Quote
*Experts* Nerseus Posted April 8, 2003 *Experts* Posted April 8, 2003 I can't duplicate this. I can see the Text property regardless of the Visible property, bound or unbound. I'm using C# but I can't imagine it works different in VB.NET. -Nerseus Quote "I want to stand as close to the edge as I can without going over. Out on the edge you see all the kinds of things you can't see from the center." - Kurt Vonnegut
stewarts Posted April 8, 2003 Author Posted April 8, 2003 I created a test form...added a textbox...added a MS Access database connection & data adapter, generated the dataset. I bound the textbox.text to a field in the dataset. I filled the dataset. I added a button and in the button_click event I displayed a messagebox showing textbox1.text. When the textbox1 visible property is set to true, I get the first value retrieved from the database table in my message display. When the Visible property is set to false, I get nothing displayed in my message display. ???? Quote
billy_bob169 Posted April 30, 2003 Posted April 30, 2003 Not sure if still applicable, but I have run into the same problem in VS.Net 2003. I simply removed the border on the text box, set the background and fore color to "Control" (to match the color of the form), set ReadOnly to true, and TabStop to false. Then I hid them behing the other related components on the form. Problem solved! :) You have probably already figured out a way around this, but hopefully this will be helpful to others with the same problem... Quote I'd rather be riding than working
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.