Quantcast
Channel: Autodesk AutoCAD forums
Viewing all articles
Browse latest Browse all 14319

How to Change view using Combobox

$
0
0

I Want to change the View of viewport according to the Combobox change event.   the drawing is updating only after exiting the macro.  My aim is to view my 3D object in different views and to modify it.

 

Here is my code.

Private Sub UserForm_Initialize()
ComboBox1.AddItem "Top"
ComboBox1.AddItem "Left"
ComboBox1.ListIndex = 0
End Sub

 

Private Sub ComboBox1_Change()
ThisDrawing.SendCommand "-View" & vbCr & ComboBox1.Text & vbCr
ThisDrawing.Regen acActiveViewport
End Sub

 


Viewing all articles
Browse latest Browse all 14319

Trending Articles