473,545 Members | 2,009 Online
Bytes | Software Development & Data Engineering Community
+ 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 1206
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.te xt"?

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.te xt"?

Chris

Nov 21 '05 #3

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

Similar topics

9
1706
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 sequence. What is the problem??? -- Tamir Khason Who am I at http://www.khason.biz/
6
9396
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 sender, PaintEventArgs e) { Graphics g = e.Graphics;
1
1603
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 Create Folder LinkButton) to create the folder. Then once that's done, they need to click the second LinkButton (the Next LinkButton) to go to the...
0
1662
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) , I'm getting a strange behavior: When I try to scroll, the text doesn't move. It only moves to a new position, if I move the scroll marks, and then...
7
2620
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: System.ArgumentException occured in System.Windows.Forms.dll
4
3933
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 textboxes and a checkbox. The behaviour I want from my app is as follows:- When the textbox (which is prior in tab order to the tab control) has...
1
2016
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 control appears at the right place. This all works just fine except the z-order, at the beginning my usercontrol contained 2 comboboxes and the z-order...
0
1173
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 controls. The only property which functions well is the one for the button. The two others, even if I do: UserControl.TextboxVisible = True or...
1
1180
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 of custom web controls. Two of these controls are derived from the TextBox control, and overide the onLoad method in order to add some client side...
0
7409
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7664
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
7921
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
0
7771
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
1
5343
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
4958
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3465
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 last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
1
1900
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1023
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.