[CLOSED] Disable Selection on TreePanel on form no valid

  1. #1

    [CLOSED] Disable Selection on TreePanel on form no valid

    Hey All,

    I'm just wondering how if possible I would disable selection on a TreePanel. Basicly I have a TreePanel with forms on each child node, each form updates or creates a record in a store when the user changes to a different node. Once the user is happy they click a save button and commit the store to the DB which works great. My problem is when a form isn't valid I want that form to be displayed until it becomes valid. I have managed the first part which was stop the user changing form but the selection on the tree changes giving the impression that you've changed to a different node which I don't want. I want the selection to stay on the same node with the error no matter where on the tree the user clicks.

    Thanks
    Last edited by Daniil; Dec 14, 2011 at 9:37 AM. Reason: [CLOSED]
  2. #2
    Hi,

    Please return false from a BeforeSelect listener of tree's selection model.
    http://docs.sencha.com/ext-js/3-4/#!...t-beforeselect
  3. #3
    Thanks that worked great

Similar Threads

  1. Replies: 8
    Last Post: Dec 18, 2014, 6:35 AM
  2. [CLOSED] fire the DirectEvent ONLY when form is valid
    By Fahd in forum 1.x Premium Help
    Replies: 2
    Last Post: Jun 07, 2012, 1:00 PM
  3. [CLOSED] Disable the hover selection on a TreePanel
    By jmcantrell in forum 1.x Premium Help
    Replies: 1
    Last Post: Feb 17, 2012, 7:14 AM
  4. [CLOSED] Grid Panel - Disable Selection
    By GavinR in forum 1.x Premium Help
    Replies: 2
    Last Post: Jun 03, 2011, 4:02 PM
  5. [CLOSED] Form status bar without valid icon
    By 78fede78 in forum 1.x Premium Help
    Replies: 2
    Last Post: Nov 05, 2010, 4:40 PM

Tags for this Thread

Posting Permissions