[CLOSED] Annoying Issue with an Accordion

  1. #1

    [CLOSED] Annoying Issue with an Accordion

    Guys

    I have an accordion with 2 tree views. I call a direct method to reload the first tree view and then use the following code to get it to refresh

    
    treeMeasures.Render(treeMeasures.ClientID, RenderMode.Replace);
    
    // Also tried insertto
    This works however the 2nd tree in the accordion think it is now expanded so the original tree is no longer visible. I then set the collapsed property of the 2nd tree however the whole thing creates a lot of screen flicker.

    I have tried suspending events and layouts but I cant stop the accordion from expanding the 2nd element.

    Is there any way to stop the accordion from auto expanding/collapsing?

    Thanks,
    Daniel
    Last edited by Daniil; Dec 13, 2013 at 5:53 AM. Reason: [CLOSED]
  2. #2
    Hello!

    Could you provide a sample with it? How do you refresh the trees?

    Try to wrap the tree in a container.
  3. #3
    Quote Originally Posted by Baidaly View Post
    Hello!

    Could you provide a sample with it? How do you refresh the trees?

    Try to wrap the tree in a container.
    Hiya and thanks for the quick response.

    I don't have a sample that is easily runable however I was loading the tree directly like tree.root.add and trying to render from a server side direct method which worked but caused the accordion to collapse. I tried rapping the tree in a container but for some reason got a script error.

    Either way does not matter as solved it by returning a json object to the client side caller and repopulating the tree client side which works like a charm. I am also guessing that this is recommended method?

    Dan
  4. #4
    Quote Originally Posted by CanopiusApplications View Post
    Either way does not matter as solved it by returning a json object to the client side caller and repopulating the tree client side which works like a charm. I am also guessing that this is recommended method?
    Do you mean that you just repopulate the tree's nodes? If so, yes, it is better when re-rendering the entire tree.
  5. #5
    Quote Originally Posted by Daniil View Post
    Do you mean that you just repopulate the tree's nodes? If so, yes, it is better when re-rendering the entire tree.
    Basically I have a tree with a filter above it. The issue was that loading the entire tree was slow (2000 items) so I added the bufferedview however this did not work properly with the client side filter code (used your example). So instead of doing a client side filter I returned to the database to get only those items matching the filter and hence the need to repopulate the tree. The repopulation does the entire tree.

    Not that this helps much but here is a screen shot.

    Click image for larger version. 

Name:	Filtered.jpg 
Views:	8 
Size:	27.4 KB 
ID:	7342Click image for larger version. 

Name:	Normal.jpg 
Views:	10 
Size:	26.1 KB 
ID:	7343

    Either way I am sorted using json return

    D
  6. #6
    Thank you for the details. I like you solution to filter the nodes on server side.

Similar Threads

  1. [CLOSED] Accordion Layout Issue
    By PriceRightHTML5team in forum 2.x Legacy Premium Help
    Replies: 11
    Last Post: Jul 18, 2013, 12:20 PM
  2. Issue with accordion v2.0 ----> v2.1
    By alpeter in forum 2.x Help
    Replies: 2
    Last Post: Dec 27, 2012, 6:58 PM
  3. [CLOSED] Accordion Layout Style Issue
    By softmachine2011 in forum 2.x Legacy Premium Help
    Replies: 4
    Last Post: Jun 25, 2012, 2:36 PM
  4. Accordion Layout Issue - v2.0 beta
    By projecta98 in forum 2.x Help
    Replies: 3
    Last Post: Mar 12, 2012, 9:39 PM
  5. [CLOSED] custom accordion layout issue
    By nhg_itd in forum 1.x Legacy Premium Help
    Replies: 5
    Last Post: Dec 30, 2011, 12:32 AM

Posting Permissions