473,325 Members | 2,712 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,325 software developers and data experts.

how to increase rows of a textarea


hi,
iwant to add dynamically some rows in same textarea when a button of
addRows is clicked.
like,if i have 2 rows in a textarea then after clicking a button the
rows must be increased to 4.
help me soon.
thanks
*** Sent via Developersdex http://www.developersdex.com ***
Sep 20 '05 #1
2 2760
Hi garima,
garima puri wrote:
hi,
iwant to add dynamically some rows in same textarea when a button of
addRows is clicked.
like,if i have 2 rows in a textarea then after clicking a button the
rows must be increased to 4.
help me soon.
thanks
*** Sent via Developersdex http://www.developersdex.com ***


Here is how i do it.

<html>
<body>
<textarea id="txtarea" cols="30" rows="5"></textarea>
<input type="button" value="Increment Rows" onClick="moreRows()">
<script language="javascript" type="text/javascript">
function moreRows() {
document.getElementById('txtarea').rows += 2;
}
</script>
<body>
</html>

-- Peroli Sivaprakasam

Sep 20 '05 #2
McA
> hi,
iwant to add dynamically some rows in same textarea when a button of
addRows is clicked.
like,if i have 2 rows in a textarea then after clicking a button the
rows must be increased to 4.


function addRow(){
document.getElementById("your_textarea_ID").rows+= 2;
}
Sep 20 '05 #3

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

Similar topics

2
by: Greg Ferris | last post by:
I have read a number of posts with techniques for limiting the max number of characters entered into a textarea, but I'm looking for some advice on how to limit the number of rows and the number of...
6
by: Tony | last post by:
The w3schools HTML tag reference for <textarea> http://www.w3schools.com/tags/tag_textarea.asp says that the attributes 'cols' and 'rows' are REQUIRED attributes for the textarea tag. Looking at...
2
by: jessDMiller | last post by:
When I refresh the page or every time I go to it, a blank row is inserted into the database. This can not happen as I'm then printing out all the contents of the database. How can I stop it? ...
5
by: SSG | last post by:
I have text area having 4 rows & 10 cols.. while I am typing in Textarea , it should not accept the 5 th row & 11 th col... Hw to create text area like that....
4
by: shaiful | last post by:
Hi all, I have a problem with checkbox. I have a database where i will get specific rows depending on user input, I dont know how many rows will select. I need to display rows on user end and which...
11
by: bharathmngl | last post by:
now iam trying to add rows dynamically into the table when i click "ADD ROW" button. It should also have the option to delete the selected row. So Please help me to find code.... And also please...
4
by: Artie | last post by:
A few months ago a customer moved from SQL 2000 to SQL 2005. The db was backed up on SQL 2000 and restored to SQL 2005. The application using this data works on SQL 2005 but takes no advantage of...
3
by: remya1000 | last post by:
I’m using Vb.net application program. I created a datagrid having text field and checkbox fields. Everything is displaying correctly. I have 9 Columns and each columns are equally separated. In...
2
by: keeru | last post by:
Instead of having a constant value for rows like rows="6" in the textarea tag, is there a way to have a dynamic value for rows based on the number of rows of the content. The content varies.
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
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
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.