- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi all, given that I understand little about ilogic, but I managed to make this rule that sets the front view of the IPT or IAM (function on both) and then does a rotation in the desired ViewCube direction (changing the reference number) and set Home view.
So far everything is perfect and I save a lot of clicks
I wanted to ask for help, I would like to implement the choice of the Front view with a mouse click on a face, let me explain better:
now it works like this:
I open the file, position the view as I want and start the rule that sets the Font view and then the Home
The function I can't do is:
After opening the file, start the rule which should ask me to click on a face of the piece and then the rule does the rest
Rule:
'Set ViewCube view to Front
Dim name1 As String = "AppViewCubeViewFrontCmd"
Dim oDef1 As ButtonDefinition = ThisApplication.CommandManager _
.ControlDefinitions.Item(name1)
oDef1.Execute
Dim oCamera As Camera
'Rotation of the ViewCube
oCamera = ThisApplication.ActiveView.Camera
oCamera.ViewOrientationType = 10759 'IsoTopRight
oCamera.Apply
'Set ViewCube view to Home
Dim name2 As String = "AppViewCubeViewHomeFloatingCmd"
Dim oDef2 As ButtonDefinition = ThisApplication.CommandManager _
.ControlDefinitions.Item(name2)
oDef2.Execute
'zoom in
ThisApplication.ActiveView.Fit
'list of view enums:
' kTopViewOrientation = 10754
' kRightViewOrientation = 10755
' kBackViewOrientation = 10756
' kBottomViewOrientation = 10757
' kLeftViewOrientation = 10758
' kIsoTopRightViewOrientation = 10759
' kIsoTopLeftViewOrientation = 10760
' kIsoBottomRightViewOrientation = 10761
' kIsoBottomLeftViewOrientation = 10762
' kFrontViewOrientation = 10764
'List ViewCube
'AppViewCubeCmd
'AppViewCubeHomeCmd
'AppViewCubeOrthographicCmd
'AppViewCubePerspectiveCmd
'AppViewCubePerspectiveOrthoCmd
'AppViewCubePropertiesCmd
'AppViewCubeViewFrontCmd
'AppViewCubeViewHomeFixedCmd
'AppViewCubeViewHomeFloatingCmd
'AppViewCubeViewLockCurrentSelectionCmd
'AppViewCubeViewResetToFrontCmd
'AppViewCubeViewTopCmd
'Go to Home
'Call ThisApplication.ActiveView.GoHome
Solved! Go to Solution.