Announcements

Announcement: We’re aware of an issue affecting starting a new topic from category pages and creating new blog posts. New topics can still be started directly from the relevant board. Learn more here.

Change VisualStyle of Viewport to Hidden

Change VisualStyle of Viewport to Hidden

jeremye86
Advocate Advocate
1,730 Views
5 Replies
Message 1 of 6

Change VisualStyle of Viewport to Hidden

jeremye86
Advocate
Advocate

Is it possible to change the Visual Style of Viewport to Hidden.  I am creating the viewport with the following code

    'CREATE THE VIEWPORTS
    center(0) = 12.745: center(1) = 5.9676
    Set pviewportObj = acadDoc.PaperSpace.AddPViewport(center, 8.2903, ViewPortHtNozzBaseplate)
    pviewportObj.Layer = "viewport"
    pviewportObj.Display True
    acadDoc.MSpace = True
    acadDoc.Application.ZoomWindow minExtBlockBasePlate, maxExtBlockBasePlate
    acadDoc.MSpace = False
    pviewportObj.DisplayLocked = True
0 Likes
Accepted solutions (1)
1,731 Views
5 Replies
  • VBA
Replies (5)
Message 2 of 6

lena.talkhina
Alumni
Alumni

Hello @jeremye86 !

Great to see you on Autodesk Community forums.

 

I see nobody reacted on your request. Did you find a solution so far?

Don't hesitate to update info in this thread to find more support from community members.

Находите сообщения полезными? Поставьте "НРАВИТСЯ" этим сообщениям! | Do you find the posts helpful? "LIKE" these posts!
На ваш вопрос успешно ответили? Нажмите кнопку "УТВЕРДИТЬ РЕШЕНИЕ" | Have your question been answered successfully? Click "ACCEPT SOLUTION" button.



Лена Талхина/Lena Talkhina
Менеджер Сообщества - Русский/Community Manager - Russian

0 Likes
Message 3 of 6

jeremye86
Advocate
Advocate
Yes I found a solution

0 Likes
Message 4 of 6

lena.talkhina
Alumni
Alumni

Thanks for the update @jeremye86 !

It would be wonderful if you can share the solution with community so we help members to find answers faster.

Находите сообщения полезными? Поставьте "НРАВИТСЯ" этим сообщениям! | Do you find the posts helpful? "LIKE" these posts!
На ваш вопрос успешно ответили? Нажмите кнопку "УТВЕРДИТЬ РЕШЕНИЕ" | Have your question been answered successfully? Click "ACCEPT SOLUTION" button.



Лена Талхина/Lena Talkhina
Менеджер Сообщества - Русский/Community Manager - Russian

0 Likes
Message 5 of 6

jeremye86
Advocate
Advocate
Accepted solution

Here is the solution.  I just used the property VisualStyle  and  ShadePlot.  I just had to do trial and error to find the correct number code.

 

center(0) = 4.2913: center(1) = 5.5097
Set pviewportObj = acadDoc.PaperSpace.AddPViewport(center, ViewPortWidthNozzSideTopV, ViewPortHtNozzSideTopV)
pviewportObj.Layer = "viewport"
pviewportObj.Display True
acadDoc.MSpace = True
pviewportObj.VisualStyle = 4
pviewportObj.ShadePlot = 3
acadDoc.Application.ZoomWindow minExtBlockNozzSideV, maxExtBlockNozzTopV
acadDoc.MSpace = False
pviewportObj.DisplayLocked = True
acadDoc.Regen acActiveViewport

Message 6 of 6

lena.talkhina
Alumni
Alumni

Thank you @jeremye86 !

I am sure other community members appreciate it.

Находите сообщения полезными? Поставьте "НРАВИТСЯ" этим сообщениям! | Do you find the posts helpful? "LIKE" these posts!
На ваш вопрос успешно ответили? Нажмите кнопку "УТВЕРДИТЬ РЕШЕНИЕ" | Have your question been answered successfully? Click "ACCEPT SOLUTION" button.



Лена Талхина/Lena Talkhina
Менеджер Сообщества - Русский/Community Manager - Russian

0 Likes