C# When I turn off my add-in and close Solidworks, the sldworks.exe process remains.

Hello,

As I mention in the title, when I turn off my add-in and close Solidworks, the sldworks.exe process remains. I'm searching for 2 days now but I can't find where I went wrong. I think it has to do with releasing some objects or so. Please help me out to clean up my code properly so it will work fine.

My code is enclosed in the .zip file.

Thanks in advance.

SolidworksApi macros