Skip to main content
April 6, 2016
Answered

how make a new view using Javascript

  • April 6, 2016
  • 1 reply
  • 533 views

Based on a given condition, I want to change what nodes are visible in a given view and then save this as a new view.

var viewIndex = 0;

var pageIndex = 0;

var a3d = this.getAnnots3D(pageIndex)[0];

var aRuntime = a3d.context3D.runtime;

var aScene = a3d.context3D.scene;

var aView = aRuntime.getView(viewIndex);

var i=0;

for (i=0; i < aScene.nodes.count; i++){

     var aNode = aScene.nodes.getByIndex(i);

     if ( ... check condition ...) {

          aNode.visible = false;

     }

}

... how to save this change to visible nodes to a new view? ...

Interactively I can go to Views>>Manage Views...>>New View>>Ok

I can't seem to find anything in the documentation or in internet searches on how to do this programmatically.

This topic has been closed for replies.
Correct answer

Re-posted on Rich Media & 3D. Answer was that you can't.

1 reply

Inspiring
April 6, 2016

You'll have better luck in the Rich Media & 3D forum: Rich Media & 3D

April 6, 2016

thanks, I'll repost this there.

Correct answer
April 7, 2016

Re-posted on Rich Media & 3D. Answer was that you can't.