Autodesk Navisworks API
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic to the Top
- Bookmark
- Subscribe
- Printer Friendly Page
Adding New SavedViewp oint Problem
Options
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
91 Views, 2 Replies
09-30-2012 06:11 PM
Hi,
I am having a problem with the following code, which is failing beacuse it thinks Newvp is an unsupported type of SavedItem.
Dim Newvp AsNew Autodesk.Navisworks.Api.SavedViewpoint(doc.CurrentViewpoint)
Newvp.DisplayName = "Test"
doc.SavedViewpoints.AddCopy(Newvp)
How can this be, when I explicitly create Newvp as a SavedViewpoint?
Cheers
Mike
Re: Adding New SavedViewp oint Problem
Options
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
09-30-2012 07:32 PM in reply to:
railrover
maybe you need to do smth like this:
Dim Newvp AsNewAutodesk.Navisworks.Api.SavedViewpoint(doc.CurrentViewpoint)
doc.SavedViewpoints.AddCopy(Newvp);
doc.SavedViewpoints.EditDisplayName(Newvp, "Test");
Re: Adding New SavedViewp oint Problem
Options
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content
10-10-2012 03:42 AM in reply to:
railrover
Hi,
please take a look at this blog if it helps.
http://adndevblog.typepad.com/aec/2012/06/naviswor
Xiaodong Liang
Developer Technical Services
Autodesk Developer Network
