Jdkriek, I used your example - thank you! and added a dialog to get pick the file name (Thanks to Curtis W. for that). Here's my iLogic:
'present a File Selection dialog
Dim oFileDlg As inventor.FileDialog = Nothing
InventorVb.Application.CreateFileDialog(oFileDlg)
oFileDlg.InitialDirectory = oOrigRefName
oFileDlg.CancelError = True
' Define the filter to select part and assembly files or any file.
'oFileDlg.Filter = "Inventor Files (*.iam;*.ipt)|*.iam;*.ipt|All Files (*.*)|*.*"
oFileDlg.Filter = "Inventor Files (*.iam;*.ipt)|*.iam;*.ipt"
' Set the title for the dialog.
oFileDlg.DialogTitle = "Choose File to Insert"
On Error Resume Next
oFileDlg.ShowOpen()
If Err.Number <> 0 Then
Return
ElseIf oFileDlg.FileName <> "" Then
selectedfile = oFileDlg.FileName
End If
'MessageBox.Show("You selected: " & selectedfile , "iLogic")
' File path to use
oPath=selectedfile
Dim oAsmCompDef As AssemblyComponentDefinition
oAsmCompDef = ThisApplication.ActiveDocument.ComponentDefinition
Dim oTG As TransientGeometry = ThisApplication.TransientGeometry
Dim oMatrix As Matrix = oTG.CreateMatrix
Dim oOccurrence As ComponentOccurrence
' Insert Loop
Dim Total As Integer
Total = InputBox("Type How Many", "Insert", "1")
If Err.Number <> 0 Then 'if there is an error it returns out
Return
ElseIf Err.Number = 0 Then 'if there is no error, it keeps working, else returns out
For X = 1 To Total
' Place Assy
oOccurrence = oAsmCompDef.Occurrences.Add(oPath, oMatrix)
oMatrix.SetTranslation(oTG.CreateVector(0, 0, 0))
oOccurrence.Grounded = True
Next
End If
ThisApplication.ActiveView.Fit
I'm very happy with this - I'm sure I'll tweak it a bit here and there, but this is great!!
Thanks all!