473,473 Members | 2,286 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

strange behavior of textbox

Hi,

I have some strange behavior in my application.
Let's say I have 2 buttons and 1 Textbox.

1. when i click on button1, it writes "hello world" in my textbox.
i see it.

2. after that, i click on button2 to take the text of my textbox and do
something with it. but instead of that, button2 returns me an empty
value ....like textbox.text = "".

how is it possible ?
i was thinking to use update or refresh, but nothing works..
it's a new behavior for me, as i already used this technique under VB6
without problem.

Who do you think about that ?

Maileen
Nov 21 '05 #1
2 1194
Maileen wrote:
Hi,

I have some strange behavior in my application.
Let's say I have 2 buttons and 1 Textbox.

1. when i click on button1, it writes "hello world" in my textbox.
i see it.

2. after that, i click on button2 to take the text of my textbox and do
something with it. but instead of that, button2 returns me an empty
value ....like textbox.text = "".

how is it possible ?
i was thinking to use update or refresh, but nothing works..
it's a new behavior for me, as i already used this technique under VB6
without problem.

Who do you think about that ?

Maileen


Can we see your code? Did you really call it "textbox.text"?

Chris

Nov 21 '05 #2
Thanks for your question Chris, but i've fixed my code using Option
strict on.

Maileen
Chris wrote:
Maileen wrote:
Hi,

I have some strange behavior in my application.
Let's say I have 2 buttons and 1 Textbox.

1. when i click on button1, it writes "hello world" in my textbox.
i see it.

2. after that, i click on button2 to take the text of my textbox and
do something with it. but instead of that, button2 returns me an empty
value ....like textbox.text = "".

how is it possible ?
i was thinking to use update or refresh, but nothing works..
it's a new behavior for me, as i already used this technique under VB6
without problem.

Who do you think about that ?

Maileen

Can we see your code? Did you really call it "textbox.text"?

Chris

Nov 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: Tamir Khason | last post by:
I have some string in variable str_tmp = "C:\TMP\" I want to display it in textbox (@-quoted), so I'm using tbx.Text = @str_tmp; but for some strange reason this does not work. it processes escape...
6
by: Sam Sungshik Kong | last post by:
Hello! I'm testing Graphics.DrawString and it's very strange. I created an event handler for the form.s Paint event. (There's no other code in the form.) private void Form1_Paint(object...
1
by: JJ | last post by:
We have an ASP.NET web form with 1 TextBox, 2 LinkButtons, and 1 RequireFieldValidator. The situation is: the user needs to enter a folder name in the TextBox and click the first LinkButton (the...
0
by: the friendly display name | last post by:
Hi, I have a filled multiline textbox on the site. I can scroll it with IE and Firefox, but under Opera (tested under 7.54, and Opera 8, under "identify as MSIE" and under Opera identification)...
7
by: Tyler Foreman | last post by:
Hello, I have a strange problem that occurs every so often in my application. It usually takes place when I hide one form and activate another. What happens is I get the following exception:...
4
by: SJ | last post by:
Hi all, I have come across a weird problem when attempting to automatically set the focus in a vb.net form to a checkbox control... In my form I have (on a tab page in a tab control) several...
1
by: Peter Proost | last post by:
Hi group I've got a usercontrol containing a textbox and alongside the textbox there's a combobox. I draw this control on top of a grid. So when the user clicks certain columns in the grid the...
0
by: Marc Robitaille | last post by:
Hello, I developed a UserControl. It has funny behavior. It is composed of three controls. A texbox, a combobox and a button. There are three properties to indicate the visibility of the three...
1
by: Sosh | last post by:
Hi, I'm pulling my hair out trying to work this out. Pehaps I am missunderstanding something - hopefully someone can shed some light on this: 1) I have a class library that contains a bunch...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.