11-21-2024
08:17 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
11-21-2024
08:17 AM
Hi @DVNK4SZN , welcome to the forum.
Here is an iLogic version based off of the VBA example included in Inventor's API help files.
Hope that helps, Curtis
Dim oDoc As AssemblyDocument oDoc = ThisApplication.ActiveDocument 'Actiate the Master model state if the active model state is substitute If oDoc.ComponentDefinition.ModelStates.ActiveModelState.ModelStateType = ModelStateTypeEnum.kSubstituteModelStateType Then oDoc.ComponentDefinition.ModelStates.Item(1).Activate oDoc = ThisApplication.ActiveDocument End If Dim oRevitExportDef As RevitExportDefinition oRevitExportDef = oDoc.ComponentDefinition.RevitExports.CreateDefinition oRevitExportDef.Location = "C:\Temp" oRevitExportDef.FileName = "MyRevitExport.rvt" oRevitExportDef.Structure = RevitExportStructureTypeEnum.kEachTopLevelComponentStructure oRevitExportDef.EnableUpdating = True ' Create RevitExport. Dim oRevitExport As RevitExport oRevitExport = oDoc.ComponentDefinition.RevitExports.Add(oRevitExportDef) , i
How to find the API help: