IV11 deletes Composite iMate??? MAJOR PROBLEM!

IV11 deletes Composite iMate??? MAJOR PROBLEM!

Anonymous
Not applicable
671 Views
6 Replies
Message 1 of 7

IV11 deletes Composite iMate??? MAJOR PROBLEM!

Anonymous
Not applicable
We are moving on to IV11 and I am testing my Product Configurators, but I am
running into a major problem!!!

Somehow, IV11 SP2 (no other hotfixes) deletes the composite iMates from the
parts (IPTs) when I am generating my models.

Anyone heard of this problem before???

As far as I can tell, I have migrated our base models succesfully. Inventor
created the "match list" for the composite iMates.
My "Copy Base Model" program also works fine, as all
parts/assemblies/drawings are being copied and renamed without any errors.
The newly copied files all have their composite iMates. No problem so far...

But when I generate/built my "Main Assembly", the iMates of my PARTS are
being deleted!!! My code only INSERTS components, which are ASSEMBLIES!!!

(All with the modified code, because Autodesk changed the "AddUsingiMate"
method)

Has anyone got any clue what is going on???

--
T. Ham
CAD Automation & Systems Administrator
CDS Engineering BV

HP xw4300 Workstation
Dual Pentium XEON 3.6 Ghz
4 GB SDRAM
NVIDIA QUADRO FX 3450/4000 SDI (Driver = 8.4.2.6)
250 GB SEAGATE SATA Hard Disc
3Com Gigabit NIC

Windows XP Professional SP2
Autodesk Inventor Series 10 SP3a
--
0 Likes
672 Views
6 Replies
Replies (6)
Message 2 of 7

Anonymous
Not applicable
I'm not sure what could be going wrong. It would be best if you could narrow
the problem down to bare minimum and provide some sample code to reproduce.
Also, you could try switching back to the old AddUsingiMates method (now
hidden and renamed to _AddUsingiMates) temporarily.

Sanjay-

"Teun Ham (IV10 SP3)" wrote in
message news:[email protected]...
We are moving on to IV11 and I am testing my Product Configurators, but I am
running into a major problem!!!

Somehow, IV11 SP2 (no other hotfixes) deletes the composite iMates from the
parts (IPTs) when I am generating my models.

Anyone heard of this problem before???

As far as I can tell, I have migrated our base models succesfully. Inventor
created the "match list" for the composite iMates.
My "Copy Base Model" program also works fine, as all
parts/assemblies/drawings are being copied and renamed without any errors.
The newly copied files all have their composite iMates. No problem so far...

But when I generate/built my "Main Assembly", the iMates of my PARTS are
being deleted!!! My code only INSERTS components, which are ASSEMBLIES!!!

(All with the modified code, because Autodesk changed the "AddUsingiMate"
method)

Has anyone got any clue what is going on???

--
T. Ham
CAD Automation & Systems Administrator
CDS Engineering BV

HP xw4300 Workstation
Dual Pentium XEON 3.6 Ghz
4 GB SDRAM
NVIDIA QUADRO FX 3450/4000 SDI (Driver = 8.4.2.6)
250 GB SEAGATE SATA Hard Disc
3Com Gigabit NIC

Windows XP Professional SP2
Autodesk Inventor Series 10 SP3a
--
0 Likes
Message 3 of 7

Anonymous
Not applicable
Hi Sanjay,

I will try to create a dataset which demonstrates the problem.

But I would also like to try the now hidden old AddUsingiMates method , but
I am getting a compile error!
This is the sub I have written:

Public Sub AddToAssemblyUsingiMates(sOccurrence As String, sAssembly As
String, Optional bVisible As Boolean = True, Optional bSaveAndCloseAssembly
As Boolean = False)

On Error GoTo ErrorHandler1:

Dim oAssDoc As AssemblyDocument
Set oAssDoc = InventorApp.Documents.Open(sAssembly, bVisible)

Dim oAsmCompDef As AssemblyComponentDefinition
Set oAsmCompDef = oAssDoc.ComponentDefinition

Dim oMatrix As Matrix
Set oMatrix = InventorApp.TransientGeometry.CreateMatrix

Dim oOcc As ComponentOccurrence
Set oOcc = oAsmCompDef.Occurrences._AddUsingiMates(sOccurrence, oMatrix)
<--- Compile error: Invalid Character

If bSaveAndCloseAssembly = True Then
oAssDoc.Save
oAssDoc.Close
End If

ErrorHandler1:
If Err <> 0 Then
MsgBox sOccurrence & " could not be added to the assembly",
vbInformation
Err.Clear
End If

Set oAssDoc = Nothing
Set oAsmCompDef = Nothing
Set oMatrix = Nothing
Set oOcc = Nothing

End Sub

I must be doing something wrong...I guess it's still too early here... 😉

--
T. Ham
CAD Automation & Systems Administrator
CDS Engineering BV

HP xw4300 Workstation
Dual Pentium XEON 3.6 Ghz
4 GB SDRAM
NVIDIA QUADRO FX 3450/4000 SDI (Driver = 8.4.2.6)
250 GB SEAGATE SATA Hard Disc
3Com Gigabit NIC

Windows XP Professional SP2
Autodesk Inventor Series 10 SP3a
--
0 Likes
Message 4 of 7

Anonymous
Not applicable
One more thing: I am running the code from Excel 2003 (VBA)...

--
T. Ham
CAD Automation & Systems Administrator
CDS Engineering BV

HP xw4300 Workstation
Dual Pentium XEON 3.6 Ghz
4 GB SDRAM
NVIDIA QUADRO FX 3450/4000 SDI (Driver = 8.4.2.6)
250 GB SEAGATE SATA Hard Disc
3Com Gigabit NIC

Windows XP Professional SP2
Autodesk Inventor Series 10 SP3a
--
0 Likes
Message 5 of 7

Anonymous
Not applicable
Sanjay,

I have send you an e-mail with a dataset which should reproduce the error.

Let me know if you have received the e-mail!

Thanks!

--
T. Ham
CAD Automation & Systems Administrator
CDS Engineering BV

HP xw4300 Workstation
Dual Pentium XEON 3.6 Ghz
4 GB SDRAM
NVIDIA QUADRO FX 3450/4000 SDI (Driver = 8.4.2.6)
250 GB SEAGATE SATA Hard Disc
3Com Gigabit NIC

Windows XP Professional SP2
Autodesk Inventor Series 10 SP3a
--
0 Likes
Message 6 of 7

Anonymous
Not applicable
You need to use square brackets for methods hidden with an underscore. So
the correct syntax is:

Set oOcc = oAsmCompDef.Occurrences.[_AddUsingiMates](sOccurrence, oMatrix)

I'll look into the dataset you've sent me.

Sanjay-

"Teun Ham (IV10 SP3)" wrote in
message news:[email protected]...
Hi Sanjay,

I will try to create a dataset which demonstrates the problem.

But I would also like to try the now hidden old AddUsingiMates method , but
I am getting a compile error!
This is the sub I have written:

Public Sub AddToAssemblyUsingiMates(sOccurrence As String, sAssembly As
String, Optional bVisible As Boolean = True, Optional bSaveAndCloseAssembly
As Boolean = False)

On Error GoTo ErrorHandler1:

Dim oAssDoc As AssemblyDocument
Set oAssDoc = InventorApp.Documents.Open(sAssembly, bVisible)

Dim oAsmCompDef As AssemblyComponentDefinition
Set oAsmCompDef = oAssDoc.ComponentDefinition

Dim oMatrix As Matrix
Set oMatrix = InventorApp.TransientGeometry.CreateMatrix

Dim oOcc As ComponentOccurrence
Set oOcc = oAsmCompDef.Occurrences._AddUsingiMates(sOccurrence, oMatrix)
<--- Compile error: Invalid Character

If bSaveAndCloseAssembly = True Then
oAssDoc.Save
oAssDoc.Close
End If

ErrorHandler1:
If Err <> 0 Then
MsgBox sOccurrence & " could not be added to the assembly",
vbInformation
Err.Clear
End If

Set oAssDoc = Nothing
Set oAsmCompDef = Nothing
Set oMatrix = Nothing
Set oOcc = Nothing

End Sub

I must be doing something wrong...I guess it's still too early here... 😉

--
T. Ham
CAD Automation & Systems Administrator
CDS Engineering BV

HP xw4300 Workstation
Dual Pentium XEON 3.6 Ghz
4 GB SDRAM
NVIDIA QUADRO FX 3450/4000 SDI (Driver = 8.4.2.6)
250 GB SEAGATE SATA Hard Disc
3Com Gigabit NIC

Windows XP Professional SP2
Autodesk Inventor Series 10 SP3a
--
0 Likes
Message 7 of 7

Anonymous
Not applicable
For what it's worth, Autodesk has been able to reproduce the error in IV11
(ID: 890628), but the problem seems to be fixed in the upcoming Inventor
release.

--
T. Ham
CAD Automation & Systems Administrator
CDS Engineering BV

HP xw4300 Workstation
Dual Pentium XEON 3.6 Ghz
4 GB SDRAM
NVIDIA QUADRO FX 3450/4000 SDI (Driver = 8.4.2.6)
250 GB SEAGATE SATA Hard Disc
3Com Gigabit NIC

Windows XP Professional SP2
Autodesk Inventor Series 10 SP3a
--
0 Likes