System.MissingMethodException

System.MissingMethodException

Anonymous
Not applicable
1,407 Views
2 Replies
Message 1 of 3

System.MissingMethodException

Anonymous
Not applicable

When I run the following code, I get an exception.

 

Spoiler
    Public Sub MySub()
        Dim MainFile As System.IO.FileInfo = Nothing
        MainFile = GoDoSomething()
    End Sub

    Public Function GoDoSomething() As System.IO.FileInfo

    End Function

The following exception happens when MainFile is initialized:

System.MissingMethodException: Method not found: 'System.Collections.Generic.List`1<System.String> Autodesk.DataManagement.Client.Framework.Vault.Forms.Settings.SelectEntitySettings.get_ActionableEntityClassIds()


I think there is something wrong with my references, but I'm not sure what the last part of the exception is referring to (get_ActionableEntityClassIds()).Everything else can be seen in the object browser. I tried using the 4.0 framework, but the version 20 vault references couldn't find themselves anymore. Any help would be most appreciated.

Thanks,

Mike

0 Likes
Accepted solutions (1)
1,408 Views
2 Replies
Replies (2)
Message 2 of 3

Anonymous
Not applicable

Let me update my findings...

 

I think I've found what is causing the exception, but I'm confused as this was working a few minor changes ago (references were upgraded), and the method in question seems to be allowable (at least what I think the method is).

 

Public Sub MySub()
    Dim MainFile As System.IO.FileInfo = Nothing
    MainFile = GoDoSomething()
End Sub

Public Function GoDoSomething() As System.IO.FileInfo
    Dim TestBool As Boolean = False
    Dim testFile As ACW.File
    Dim ProjFolder As ACW.Folder = mgrAdmin.DocumentService.GetFolderByPath("$/Projects/")
    Dim Folder5000 As New VDF.Vault.Currency.Entities.Folder(conn, ProjFolder)
    Dim EntSettings As VDF.Vault.Forms.Settings.SelectEntitySettings = New VDF.Vault.Forms.Settings.SelectEntitySettings()
    With EntSettings
        .ActionableEntityClassIds.Add("FILE")
        .DialogCaption = "Select Welded Main Assembly Drawing"
        .MultipleSelect = False
        .ConfigureActionButtons("Select File", Nothing, Nothing, Nothing)
        .InitialBrowseLocation = Folder5000
    End With
End Function

 

The following exception happens when MainFile is initialized:

System.MissingMethodException: Method not found: 'System.Collections.Generic.List`1<System.String> Autodesk.DataManagement.Client.Framework.Vault.Forms.Settings.SelectEntitySettings.get_ActionableEntityClassIds()


I think there is something wrong with my references, but I'm not sure what the last part of the exception is referring to (get_ActionableEntityClassIds()).Everything else can be seen in the object browser. I tried using the 4.0 framework, but then the version 20 vault references couldn't find themselves anymore. Any help would be most appreciated. I don't understand how anything in the exception relates to the line of code that blows up.

Thanks,

Mike

0 Likes
Message 3 of 3

Anonymous
Not applicable
Accepted solution

I got this working hurridley before winter break. I believe the problem was coming from the fact that I had just upgraded Inventor, and hadn't installed the updates for 2015. I could be mistaken, but it was not a code issue. Either that or it came from a duplicate reference that I remember finding using Process Explorer. Sorry I couldn't be more specific.

 

Mike

0 Likes