{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-guides/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":[]},"type":"markdown"},"seo":{"title":"Organizing Nodes In The Layers Window","description":"Accelerate E&P application development and protect your innovation by consuming our Data and Domain APIs / Platform APIs.","lang":"en-US","meta":[{"name":"robots","content":"noindex"}],"llmstxt":{"hide":false}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"organizing-nodes-in-the-layers-window","__idx":0},"children":["Organizing Nodes In The Layers Window"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"organizing-nodes-in-the-desktop-window","__idx":1},"children":["Organizing nodes in the desktop window"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"how-to-create-an-empty-folder-at-the-root-of-a-window","__idx":2},"children":["How to create an empty folder at the root of a window"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"     VisualFolder newFolder = new VisualFolder();\n     newFolder.setDisplayName(\"myName\");\n     VisualFolder rootFolder =  ((AbstractViewerWindow) window).getRootFolder();\n     rootFolder.addNode(newFolder);\n"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"how-to-move-a-visual-to-another-folder","__idx":3},"children":["How to move a visual to another folder"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"     IVisual visual = ...\n     VisualFolder targetVisualFolder = ...\n     VisualFolder currentVisualFolder = visual.getParentFolder();\n     targetVisualFolder.addNode(0, visual);\n     currentVisualFolder.removeNode(visual);\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["In the default case where the visual is at the root of its window, visual.getParentFolder() returns the same object as ((AbstractViewerWindow) window).getRootFolder()"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"how-to-move-a-visual-within-its-own-folder","__idx":4},"children":["How to move a visual within its own folder"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"IVisual visual = ...\nVisualFolder visualFolder = visual.getParentFolder();\nint pos = visualFolder.indexOf(visual);\nvisualFolder.moveNode(0, visual); // moves to the top\nvisualFolder.moveNode(visualFolder.getNodes().length - 1, visual); // moves to the bottom\nvisualFolder.moveNode(pos + 1, visual); // moves down one position\n"},"children":[]}]},"headings":[{"value":"Organizing Nodes In The Layers Window","id":"organizing-nodes-in-the-layers-window","depth":1},{"value":"Organizing nodes in the desktop window","id":"organizing-nodes-in-the-desktop-window","depth":2},{"value":"How to create an empty folder at the root of a window","id":"how-to-create-an-empty-folder-at-the-root-of-a-window","depth":3},{"value":"How to move a visual to another folder","id":"how-to-move-a-visual-to-another-folder","depth":3},{"value":"How to move a visual within its own folder","id":"how-to-move-a-visual-within-its-own-folder","depth":3}],"frontmatter":{"title":"Organizing Nodes In The Layers Window","pageId":"intviewer-apis-for-windows/organizing-nodes-in-the-layers-window","seo":{"title":"Organizing Nodes In The Layers Window"}},"lastModified":"2026-10-22T14:32:05.576Z","pagePropGetterError":{"message":"","name":""}},"slug":"/solutions/intviewer/intviewer-apis-for-windows/organizing-nodes-in-the-layers-window","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}