1. #1
    Ext User
    Join Date
    Oct 2008
    Posts
    26
    Vote Rating
    0
    DirtDog is on a distinguished road

      0  

    Default TextArea Scroll to Top

    TextArea Scroll to Top


    I did the usual search for an answer but didn't find any.

    I want to scroll to the top of a Ext.form.TextArea.

    How do I do this?

    Ed

  2. #2
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,499
    Vote Rating
    46
    Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    Same was as you always scroll scrollable elements to the top in all the HTML pages you've ever written.

    Set the scrollTop of the HtmlElement to 0

  3. #3
    Ext User
    Join Date
    Oct 2008
    Posts
    26
    Vote Rating
    0
    DirtDog is on a distinguished road

      0  

    Default No Joy

    No Joy


    I tried your suggestion. No go. The scroll bar stays at the bottom.

    I have several cards in a card layout.

    I switch to the form with the TextArea, scroll to the bottom, then switch to another form
    in the card layout, then switch back to the form with the TextArea.

    Right before calling setActiveItem to switch to the form with the TextArea I call load on a Store, the Store Load event calls:

    function CLP_AccountLettersStoreLoad(StoreObj, Records, Options)
    {
    if (Records.length == 0) return;
    var FormObj = WindowObj.findById('AccountLettersForm');
    FormObj.getForm().loadRecord(Records[0]);
    CLP_AccountLettersScrollTop();
    }

    function CLP_AccountLettersScrollTop()
    {
    var FormObj = WindowObj.findById('AccountLettersForm');
    var LetterObj = FormObj.findById('Letter');
    LetterObj.getEl().scrollTop = 0;
    FormObj.doLayout();
    }

  4. #4
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,499
    Vote Rating
    46
    Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    getEl.

    What does it return?

  5. #5
    Ext User
    Join Date
    Oct 2008
    Posts
    26
    Vote Rating
    0
    DirtDog is on a distinguished road

      0  

    Default Joy

    Joy


    Got it. Works.

    Thanks,

    Ed

Thread Participants: 1

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi