I found code in the Access Knowledge Base that allows you to register if programs are open by applicattion name. Have a search through there incorporate your code and then search for the DUN to see if it is active. Haven't tried it myself but I am sure it is possible.