<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Request: List of all types that can be returned via &amp;quot;InventorApplication.ActiveEditObject&amp;quot; in Inventor Programming - iLogic, Macros, AddIns &amp; Apprentice</title>
    <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/request-list-of-all-types-that-can-be-returned-via-quot/m-p/13098090#M173121</link>
    <description>&lt;P&gt;As a follow-up, I did find what I believe is the list I recalled.&lt;BR /&gt;It's within the Remarks on this help page for the &lt;STRONG&gt;OnNewEditObject&lt;/STRONG&gt; &lt;EM&gt;ApplicationEvent&lt;/EM&gt;:&amp;nbsp;&lt;A href="https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=ApplicationEvents_OnNewEditObject" target="_blank"&gt;https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=ApplicationEvents_OnNewEditObject&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;SPAN&gt;Valid objects for edit objects are documents, 2d and 3d sketches, and drawing sheets.&lt;/SPAN&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;But clearly this list isn't complete, but just supplying examples. I know there are additional valid objects such as &lt;U&gt;FlatPattern&lt;/U&gt;.&lt;BR /&gt;&lt;BR /&gt;I just don't know what /all/ the ActiveEditObject can encompass. Does it return "PartFeature" (or specific subtype of) if a Part model feature is being edited? etc, etc, etc.&lt;/P&gt;</description>
    <pubDate>Mon, 21 Oct 2024 15:16:57 GMT</pubDate>
    <dc:creator>josh.nieman</dc:creator>
    <dc:date>2024-10-21T15:16:57Z</dc:date>
    <item>
      <title>Request: List of all types that can be returned via "InventorApplication.ActiveEditObject"</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/request-list-of-all-types-that-can-be-returned-via-quot/m-p/13097973#M173117</link>
      <description>&lt;P&gt;It may just be that my google-fu is weak this Monday morning, but I thought I recalled seeing a list of all object types that can be accessible via "ActiveEditObject"&lt;/P&gt;&lt;P&gt;&lt;EM&gt;(note: I do not mean ActiveEditDocument)&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I thought I came across it somewhere, but I cannot find it, if I ever did.&lt;BR /&gt;I just want to make myself an easy helper function to get "ActiveEditObject" as well as automatically returning what it's TYPE is, in some manner.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;----&amp;gt; Has anyone found or made a list of all ActiveEditObject TYPE possibilities that you'd be willing to share?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Alternatively, is there even a way one could efficiently even collect this on their own?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I could list all I could THINK of but surely I'd miss some or many.&lt;/P&gt;</description>
      <pubDate>Mon, 21 Oct 2024 14:25:50 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/request-list-of-all-types-that-can-be-returned-via-quot/m-p/13097973#M173117</guid>
      <dc:creator>josh.nieman</dc:creator>
      <dc:date>2024-10-21T14:25:50Z</dc:date>
    </item>
    <item>
      <title>Re: Request: List of all types that can be returned via "InventorApplication.ActiveEditObject"</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/request-list-of-all-types-that-can-be-returned-via-quot/m-p/13098090#M173121</link>
      <description>&lt;P&gt;As a follow-up, I did find what I believe is the list I recalled.&lt;BR /&gt;It's within the Remarks on this help page for the &lt;STRONG&gt;OnNewEditObject&lt;/STRONG&gt; &lt;EM&gt;ApplicationEvent&lt;/EM&gt;:&amp;nbsp;&lt;A href="https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=ApplicationEvents_OnNewEditObject" target="_blank"&gt;https://help.autodesk.com/view/INVNTOR/2024/ENU/?guid=ApplicationEvents_OnNewEditObject&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;SPAN&gt;Valid objects for edit objects are documents, 2d and 3d sketches, and drawing sheets.&lt;/SPAN&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;But clearly this list isn't complete, but just supplying examples. I know there are additional valid objects such as &lt;U&gt;FlatPattern&lt;/U&gt;.&lt;BR /&gt;&lt;BR /&gt;I just don't know what /all/ the ActiveEditObject can encompass. Does it return "PartFeature" (or specific subtype of) if a Part model feature is being edited? etc, etc, etc.&lt;/P&gt;</description>
      <pubDate>Mon, 21 Oct 2024 15:16:57 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/request-list-of-all-types-that-can-be-returned-via-quot/m-p/13098090#M173121</guid>
      <dc:creator>josh.nieman</dc:creator>
      <dc:date>2024-10-21T15:16:57Z</dc:date>
    </item>
    <item>
      <title>Re: Request: List of all types that can be returned via "InventorApplication.ActiveEditObject"</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/request-list-of-all-types-that-can-be-returned-via-quot/m-p/13098091#M173122</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/4998597"&gt;@josh.nieman&lt;/a&gt;.&amp;nbsp; Good question.&amp;nbsp; I have never thought about making a list like that, or why I would want a list like that, but it does sound interesting.&amp;nbsp; I can think of several scenarios where we have to 'enter an edit mode' of something, in order to edit them.&amp;nbsp; In every one of those situations, there will be a change to what 'object' is the active edit object.&amp;nbsp; And when exiting that 'edit mode' it would change again.&amp;nbsp; I will post a couple code examples that could be used for exploration purposes.&lt;/P&gt;
&lt;P&gt;This first example is the most basic, and could be used as an external rule, and place a button for it in the ribbon.&amp;nbsp; Click it any time you want to, and it will write the Type of the currently active edit object to the iLogic Log window, for review.&amp;nbsp; That could also be changed to something like a MsgBox or MessageBox.Show, or similar.&lt;/P&gt;
&lt;LI-CODE lang="general"&gt;Dim AEO As Object = ThisApplication.ActiveEditObject
Logger.Info("ActiveEditObject Type = " &amp;amp; TypeName(AEO))&lt;/LI-CODE&gt;
&lt;P&gt;However, there is actually an Inventor API event for that type of situation.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.autodesk.com/view/INVNTOR/2025/ENU/?guid=ApplicationEvents_OnNewEditObject" target="_blank" rel="noopener"&gt;ApplicationEvents.OnNewEditObject Event&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;And below is a relatively basic iLogic rule which includes an example of initializing that event handler.&amp;nbsp; However, once launched, it will continue running in the background of Inventor until you quit or restart Inventor, because I have not programmed in a 'back-door' way to eliminate it when something else happens later.&lt;/P&gt;
&lt;LI-CODE lang="general"&gt;Sub Main
	InvApp = ThisApplication
	AppEvents = InvApp.ApplicationEvents
	AddHandler AppEvents.OnNewEditObject, AddressOf AppEvents_OnNewEditObject
End Sub

Private InvApp As Inventor.Application
Private AppEvents As Inventor.ApplicationEvents

Sub AppEvents_OnNewEditObject(EditObject As Object, BeforeOrAfter As EventTimingEnum, Context As NameValueMap, ByRef HandlingCode As HandlingCodeEnum)
	If BeforeOrAfter = EventTimingEnum.kAfter Then
		Logger.Info("EditObject Type = " &amp;amp; TypeName(EditObject))
		If Context IsNot Nothing AndAlso Context.Count &amp;gt; 0 Then
			Dim oActiveDoc As Inventor.Document = Nothing
			Dim oActiveEditObj As Object = Nothing
			For i As Integer = 1 To Context.Count
				Dim sName As String = Context.Name(i)
				Dim oValue As Object = Context.Value(sName)
				If sName = "ActiveDocument" Then
					oActiveDoc = oValue
					Logger.Info("ActiveDocument = " &amp;amp; oActiveDoc.FullDocumentName)
				ElseIf sName =  "ActiveEditObject" Then
					oActiveEditObj = oValue
					Logger.Info("ActiveEditObject Type = " &amp;amp; TypeName(oActiveEditObj))
				End If
			Next
		End If
	End If
End Sub&lt;/LI-CODE&gt;
&lt;P&gt;If this solved your problem, or answered your question, please click &lt;SPAN&gt;&lt;STRONG&gt; ACCEPT SOLUTION &lt;/STRONG&gt;&lt;/SPAN&gt;.&lt;BR /&gt;Or, if this helped you, please click (LIKE or KUDOS) &lt;img class="lia-deferred-image lia-image-emoji" src="https://forums.autodesk.com/html/@7401B55A0A518861312A0F851CD29320/emoticons/1f44d.png" alt=":thumbs_up:" title=":thumbs_up:" /&gt;.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 21 Oct 2024 15:17:26 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/request-list-of-all-types-that-can-be-returned-via-quot/m-p/13098091#M173122</guid>
      <dc:creator>WCrihfield</dc:creator>
      <dc:date>2024-10-21T15:17:26Z</dc:date>
    </item>
    <item>
      <title>Re: Request: List of all types that can be returned via "InventorApplication.ActiveEditObject"</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/request-list-of-all-types-that-can-be-returned-via-quot/m-p/13098166#M173124</link>
      <description>&lt;P&gt;I think you and I came to a pretty similar conclusion.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There's many types that can be edited in-place but not really any convenient list anywhere. So far my only idea is like you recommended; add an event handler that'll log each ActiveEditObject type, launch Inventor, and "in-place edit" as many things as I could think of and start with that list, using the OnNewEditObject (as linked in the OP) event handler in my add-in.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Ah well. If no one supplies a good list and I end up compiling my own, I'll follow up and share. Otherwise I may just add the specific object Types I care about as-needed and not worry about it.&lt;/P&gt;</description>
      <pubDate>Mon, 21 Oct 2024 15:53:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/request-list-of-all-types-that-can-be-returned-via-quot/m-p/13098166#M173124</guid>
      <dc:creator>josh.nieman</dc:creator>
      <dc:date>2024-10-21T15:53:01Z</dc:date>
    </item>
    <item>
      <title>Re: Request: List of all types that can be returned via "InventorApplication.ActiveEditObject"</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/request-list-of-all-types-that-can-be-returned-via-quot/m-p/13098233#M173126</link>
      <description>&lt;P&gt;Likely the 3 least expected are while working on a weldment type assembly, because there are so few code examples of doing those types of things here in this forum.&amp;nbsp; Generally, when you have a weldment type assembly open, but are are not yet in any specific 'edit mode', you just get something very generic, and useless like "_DocumentClass".&amp;nbsp; But then there are the "Welds", Machining", and "Preparations".&amp;nbsp; Each of those sub environments can actually be activated by code also, when starting from the&amp;nbsp;&lt;A href="https://help.autodesk.com/view/INVNTOR/2025/ENU/?guid=GUID-WeldmentComponentDefinition" target="_blank" rel="noopener"&gt;WeldmentComponentDefinition&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.autodesk.com/view/INVNTOR/2025/ENU/?guid=Welds_Edit" target="_blank" rel="noopener"&gt;Welds.Edit&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.autodesk.com/view/INVNTOR/2025/ENU/?guid=Machining_Edit" target="_blank" rel="noopener"&gt;Machining.Edit&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.autodesk.com/view/INVNTOR/2025/ENU/?guid=Preparations_Edit" target="_blank" rel="noopener"&gt;Preparations.Edit&lt;/A&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 21 Oct 2024 16:19:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/request-list-of-all-types-that-can-be-returned-via-quot/m-p/13098233#M173126</guid>
      <dc:creator>WCrihfield</dc:creator>
      <dc:date>2024-10-21T16:19:49Z</dc:date>
    </item>
  </channel>
</rss>

