iLogic Error in getting assembly component defination

iLogic Error in getting assembly component defination

sanjaysy
Enthusiast Enthusiast
409 Views
1 Reply
Message 1 of 2

iLogic Error in getting assembly component defination

sanjaysy
Enthusiast
Enthusiast

Hi,

 

i have the following code, 

 

SyntaxEditor Code Snippet

    'On Error Resume Next
    Dim oDoc As Document
    oDoc = ThisApplication.ActiveDocument
    
    If oDoc.DocumentType <> kAssemblyDocumentObject Then
        Exit Sub
    End If
    
    'MsgBox (odoc.documenttype)
            
    Dim oDef As AssemblyComponentDefinition
    
    oDef = oDoc.ComponentDefinition

 

when i run the above code, following error pops up,

 

Error in rule: iAssembly-GenerateMember, in document: iAssembly.iam

Member not found. (Exception from HRESULT: 0x80020003 (DISP_E_MEMBERNOTFOUND))

 

 

System.Runtime.InteropServices.COMException (0x80020003): Member not found. (Exception from HRESULT: 0x80020003 (DISP_E_MEMBERNOTFOUND))
at Microsoft.VisualBasic.CompilerServices.LateBinding.LateGet(Object o, Type objType, String name, Object[] args, String[] paramnames, Boolean[] CopyBack)
at Microsoft.VisualBasic.CompilerServices.NewLateBinding.LateGet(Object Instance, Type Type, String MemberName, Object[] Arguments, String[] ArgumentNames, Type[] TypeArguments, Boolean[] CopyBack)
at LmiRuleScript.Main()
at Autodesk.iLogic.Exec.AppDomExec.ExecRuleInAssembly(Assembly assem)
at iLogic.RuleEvalContainer.ExecRuleEval(String execRule)

 

 

can some help me to solve this.

 

Thanks in advance,

 

Regards,
Sanjay


Regards,
Sanjay
0 Likes
410 Views
1 Reply
Reply (1)
Message 2 of 2

LishuangLu
Autodesk
Autodesk

Did you encounter this issue with other assemblies?

The code runs well in my side with both assembly and iAssembly files.

 

If this only relates with typical iassembly, could you share that file with me for more investigation?

 

Thanks,

-Lisa

0 Likes