Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.
fakeru
383 Views, 2 Replies

Command doesn't get executed

I'm trying to invoke a command execution, but without any success.

Dim oCopyControlDef As ControlDefinition
    Set oCopyControlDef = ThisApplication.CommandManager.ControlDefinitions.Item("PartMoveFaceCmd")
    oCopyControlDef.Execute

I run this code when I have a part open. I tried to select a face before running the conde, but still doesn't show up...

Any ideas why?

 

Thanks

Alexandru

Autodesk Inventor 2015 Certified Professional
CadUser46
in reply to: fakeru

Fakeru.  I never realised this until now but the move face command has been retired, at least in 2016.  Its still listed in the control definitions i guess as a legacy command but its been replaced with PartDirectCmd.

 

Public Sub MoveFace()

    Call ThisApplication.CommandManager.ControlDefinitions.Item("PartDirectCmd").Execute

End Sub

Did you find this reply helpful ? If so please use the Accept as Solution or Kudos button below.

---------------------------------------------------------------------------------------------------------------------------
Inventor 2010 Certified Professional
Currently using 2023 Pro
fakeru
in reply to: CadUser46

thanks forhe info. I guess I will have to stick with DirectEdit, although I would prefer moveface command.

 

 

Autodesk Inventor 2015 Certified Professional