Memory management

I’m just a bit confused about how to handle the memory in a PC SDK app.

I open up the controller with those rows:

robControl = new Controller(GUID);

robControl.Logon(UserInfo.DefaultUser);

…and later on I finnish the session with:

Controller.ReleaseUnmanagedResources();

robControl.Logoff();

robControl.Dispose();

robControl = null;

The problem is that sometimes it seems to be some memory leaks:

[Output window]

The program ‘[2516] HMI.exe: Managed’ has exited with code 0 (0x0).

Perhaps I have missed something?

Regards axel