AnsweredAssumed Answered

iEdmFile8.GetDerivedBoms trouble

Question asked by Benjamin Abshire on Feb 7, 2012
Latest reply on Feb 8, 2012 by Lee CS Young

All,

 

I am experiencing trouble with the following code that I got from another post awhile back. This code works perfectly in a Visual Basic 2010 windows Form App but does not work in Microsoft Access 2007 VBA. The error occurs while trying to use EdmBomInfo (boms) as an argument to the GetDerivedBoms call.

 

    Dim vault As IEdmVault10

    Set vault = New EdmVault5

    vault.LoginAuto "PDM_Vault", 0

   

    Dim File As IEdmFile7

    Dim Folder As IEdmFolder5

    Set Folder = vault.RootFolder

    Me.txbFilePath.SetFocus

    Set File = vault.GetFileFromPath(Me.txbFilePath.Text, Folder)

 

'good upto here

   

    Dim boms() As EdmBomInfo

    File.GetDerivedBoms (boms)

 

The error says "Compile Error: Type mismatch: Array or user-defined type expected" and (boms) is highlighted.

 

Any suggestions on how I can fix this?

Thanks in advance.

Outcomes