AnsweredAssumed Answered

Stand-alone PDM app - AddInSrv.exe has many processes open

Question asked by Chris Manger on Dec 18, 2018
Latest reply on Dec 20, 2018 by Michael Spens

I created a stand-alone application that searches my PDM vault and opens a PDF.  The user inputs the part number, the app searches for a PDF with that part number, then opens it.  It appears that the 'file.GetFileCopy' method launches the AddInSrv.exe process.  The issue I am having is this process stays open and creates a new process when the user opens for another PDF.    After opening 10 PDFs, there are (10) or more AddInSrv.exe processes open, each using 10MB of memory.  I thought that setting the objects File and Vault to nothing would solve this, but it does not.  I thought about adding code that will simply kill this process after the PDF is open, but I am not sure if this would cause an adverse effects.

 

Any ideas what may be causing this and how I can unload this process after file is opened?

 

CODE:

    Private Sub ListBox1_DoubleClick(sender As Object, e As EventArgs) Handles ListBox1.DoubleClick
        Dim vault As New EdmVault5
        vault.LoginAuto("MYVAULT", 0)


        Dim fullPath = ListBox1.SelectedItem.ToString()
        Dim File As IEdmFile5 = Nothing
        Dim ParentFolder As IEdmFolder5 = Nothing
        File = vault.GetFileFromPath(fullPath, ParentFolder)
        File.GetFileCopy(0)


        'MsgBox(fullPath)
        System.Diagnostics.Process.Start(fullPath)
        File = Nothing
        vault = Nothing


    End Sub

Outcomes