Jump to content

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Find out more here. X
X


Photo

How to Change the Height of a TextArea?


  • Please log in to reply
8 replies to this topic

#1 Zohar

Zohar

  • Active Members
  • PipPipPipPipPipPip
  • 646 posts

Posted 22 September 2012 - 05:40 PM

Hi


In many webpages, we have a TextArea element, and often its Height is not enough.

I am trying to change the Height of a TextArea,
and I succeed in changing the value,
however the Element does not "refresh" itself according to its new height..

Only If I drag it slightly, then it "jumps" to the Height that I set.

The code I have for now is this:
Local $TA   =$oIE.document.getElementById("textarea_id") $TA.style.height="575px"


What do I need to add to make it work?


Thank you
Zohar







#2 FireFox

FireFox

    It slips through our fingers, like a fist full of sand.

  • MVPs
  • 5,380 posts

Posted 22 September 2012 - 06:24 PM

Hi,
Try this :
Local $TA =$oIE.document.getElementById("textarea_id") $TA.style.height="575px !important"


Br, FireFox.

OS : Win XP SP2 (32 bits) / Win 7 SP1 (64 bits) / Win 8 (64 bits) | Autoit version: latest stable / beta.

Hardware : Intel® Core™ i5-2400 CPU @ 3.10Ghz / 8 GiB RAM DDR3.

My UDFs : Skype UDF | TrayIconEx UDF | GUI Panel UDF | Excel XML UDF | Is_Pressed_UDF

My Projects : YouTube Multi-downloader | FTP Easy-UP | Lock'n | WinKill | AVICapture | Skype TM | Tap Maker | ShellNew | Scriptner | Const Replacer | FT_Pocket | Chrome theme maker

My Examples : Capture toolIP Camera | Crosshair | Draw Captured Region | Picture Screensaver | Jscreenfix | Drivetemp | Picture viewer

My Snippets : Basic TCP | Systray_GetIconIndex | Intercept End task | Winpcap various | Advanced HotKeySet | Transparent Edit control

Updated 07 November, 2013 - If you find dead links please send me a PM, do not post in the topics !


#3 kylomas

kylomas

    FUBAR

  • MVPs
  • 3,087 posts

Posted 22 September 2012 - 06:32 PM

Zohar,

I believe that the IE object has a refresh method. So you might try
 $oie.refresh
after you alter the property.

kylomas

"Really?, How Do you know the're not random numbers?"

 

Forum Rules         Procedure for posting code

 

"A child educated only at school is an uneducated child."

    - George Santayana

 

"Never miss a good chance to shut up."

    - Will Rogers
 


#4 Zohar

Zohar

  • Active Members
  • PipPipPipPipPipPip
  • 646 posts

Posted 25 September 2012 - 07:32 AM

kylomas:

Thank you..

I need to do it on the current page, with its current content,
so Refreshing will not be a good solution for this here..
I need the page to remain as it is, without being refreshed..


FireFox:

Is this real?
To write the browser "!important"? :)
If yes, then it did not work...

#5 Myicq

Myicq

    Universalist

  • Active Members
  • PipPipPipPipPip
  • 278 posts

Posted 25 September 2012 - 07:36 AM

@Zohar: the !important is part of CSS. The styles on the page determine if it's needed or not.

#6 czardas

czardas

  • MVPs
  • 7,049 posts

Posted 25 September 2012 - 07:50 AM

Why resize it? Can't you just paste your text in there?

#7 Zohar

Zohar

  • Active Members
  • PipPipPipPipPipPip
  • 646 posts

Posted 25 September 2012 - 03:20 PM

@Zohar: the !important is part of CSS. The styles on the page determine if it's needed or not.

Hi Myicq
Thank you..
Weird that it doesn't work for me :/
When ran, it causes an Error..

Why resize it? Can't you just paste your text in there?

There's no ready-made text.
I want to use this when I type in a forum.

#8 czardas

czardas

  • MVPs
  • 7,049 posts

Posted 26 September 2012 - 08:58 AM

There's no ready-made text.
I want to use this when I type in a forum.


What's wrong with creating ready made text in an editor? :blink:

#9 hannes08

hannes08

    my oh my

  • Active Members
  • PipPipPipPipPipPip
  • 944 posts

Posted 26 September 2012 - 09:09 AM

If you need to resize a textbox you can use Google Chrome. The function is built in there.
Regards,Hannes
Spoiler




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users