473,385 Members | 1,518 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Text Box Control MaxLenght Property Is Not Working


Hi All,

I have developed one web application.
In that I used aspnet web textBox control.
I have set maxlength property for that text box 300 and TextMode property as
multiline .

When i typed more than 3 or 4 line each line contains 30 to 40 characters,
If i clicked button for passing textbox value, that time my web page is not
responsding (no action taken).

The same page without refereshing if i delete some characters from my
textbox.
It is working.

Can someone help me for this?

--
Regards,
Dhana

Dec 31 '05 #1
3 3447
Dhana,

What browser are you using?

"Dhana" <dh***@celtycs-consulting.com> wrote in message
news:O4**************@TK2MSFTNGP11.phx.gbl...

Hi All,

I have developed one web application.
In that I used aspnet web textBox control.
I have set maxlength property for that text box 300 and TextMode property
as multiline .

When i typed more than 3 or 4 line each line contains 30 to 40 characters,
If i clicked button for passing textbox value, that time my web page is
not responsding (no action taken).

The same page without refereshing if i delete some characters from my
textbox.
It is working.

Can someone help me for this?

--
Regards,
Dhana

Dec 31 '05 #2
A TextBox in MultiLine mode is rendered as a TextArea HTML control. TextArea
as opposed to an Imput control does not have a maxlength property. It will
be ignored in the TextBox.

There are some 3rd party controls and projects out there that attempt to
control length with javascript for a multiline textbox. I haven't used any
of them so can't comment.

--

Andrew Robinson
www.binaryocean.com
www.bellinghamdotnet.org
"Dhana" <dh***@celtycs-consulting.com> wrote in message
news:O4**************@TK2MSFTNGP11.phx.gbl...

Hi All,

I have developed one web application.
In that I used aspnet web textBox control.
I have set maxlength property for that text box 300 and TextMode property
as multiline .

When i typed more than 3 or 4 line each line contains 30 to 40 characters,
If i clicked button for passing textbox value, that time my web page is
not responsding (no action taken).

The same page without refereshing if i delete some characters from my
textbox.
It is working.

Can someone help me for this?

--
Regards,
Dhana

Dec 31 '05 #3
Ah yeah...

Try using a javscript function like:

function limitTextarea(textarea, maxlength) {
if (textarea.value.length > maxlength)
textarea.value = textarea.value.substring(0, maxlength);
}

and set the onchange attribute (either programatically with
textbox.attribute.add() or declaratively) on the textbox to call the
function.

"Andrew Robinson" <ne****@nospam.nospam> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl...
A TextBox in MultiLine mode is rendered as a TextArea HTML control.
TextArea as opposed to an Imput control does not have a maxlength property.
It will be ignored in the TextBox.

There are some 3rd party controls and projects out there that attempt to
control length with javascript for a multiline textbox. I haven't used any
of them so can't comment.

--

Andrew Robinson
www.binaryocean.com
www.bellinghamdotnet.org
"Dhana" <dh***@celtycs-consulting.com> wrote in message
news:O4**************@TK2MSFTNGP11.phx.gbl...

Hi All,

I have developed one web application.
In that I used aspnet web textBox control.
I have set maxlength property for that text box 300 and TextMode property
as multiline .

When i typed more than 3 or 4 line each line contains 30 to 40
characters,
If i clicked button for passing textbox value, that time my web page is
not responsding (no action taken).

The same page without refereshing if i delete some characters from my
textbox.
It is working.

Can someone help me for this?

--
Regards,
Dhana


Dec 31 '05 #4

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

Similar topics

2
by: Brian | last post by:
NOTE ALSO POSTED IN microsoft.public.dotnet.framework.aspnet.buildingcontrols I have solved most of my Server Control Collection property issues. I wrote an HTML page that describes all of the...
1
by: Maurice Mertens | last post by:
Hi, I'm currently working on an app in VB.NET 2005 which uses a splashscreen. In the 'my project' settings I used the 'Spash screen' setting to set the form that will be the splash screen. ...
3
by: Giuseppe Dini | last post by:
if I set the parameter maxlenght of a usercontrol, am I assured that all the browsers will accept such a limitation or is this just an IE feature? -- Giuseppe
31
by: Kathy | last post by:
I would like to get the old and new value for a change made to a text box so that I can store them in a change history table. What is the best way to do this? I am just learning VB 2005; porting...
3
by: dmbuso | last post by:
I have a money field defined in a SQL Server 05 database with a value of 49.50. Also, it displays in SQL Server as 49.5000. I have a form in VB.NET 2005 and I'm using the new MaskedTextBox control...
3
by: michael sorens | last post by:
The documentation for the RichTextBox is sketchy at best. I want to do a very simple task but I cannot find information on this. I am using a RichTextBox as an output window. Some text I want to...
3
by: =?Utf-8?B?U3RldmVU?= | last post by:
I want to create tabs in the TabControl that are aligned on either the right or left side, but no text shows when doing this. Is there an issue here or a work around. Text for tabs on top or...
0
by: hcuellar | last post by:
Hi. Please I need your help for this: After a database query, a table is created with a cell for each information retrieved, and for each record, two buttons, and second one have besides it...
11
by: =?Utf-8?B?UmF5IE1pdGNoZWxs?= | last post by:
Hello, I know I sound like a one-note Johnny on this but I'm still looking for a solution. I need to display characters coming in from a serial port or a socket. I also need to be able to type...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.