How to get a list of background processes on BlackBerry

I am looking for content corresponding to net.rim.device.api.system.ApplicationManager.getVisibleApplications(), but includes applications that may not/have no UI. Any ideas ?

Unreasonably complex solutions are popular, and I am slowly growing to make sure that there is no simple single call to do this…

If you know the application name, you can detect whether it is running or not by checking the size of the array containing all AppDescriptors that actually run this application.

int codeModuleHandle = CodeModuleManager.getModuleHandle(applicationPackageName);

if (codeModuleHandle != 0) {
ApplicationDescriptor[] apDes = CodeModuleManager.getApplicationDescriptors(codeModuleHandle);
}

You can imagine a code to get all installed applications and then check

I am looking for content corresponding to net.rim.device.api.system.ApplicationManager.getVisibleApplications(), but includes applications that may not/have no UI. Any ideas?

Unreasonably complex solutions are popular, and I am slowly growing to make sure that there is no simple single call to do this…

If you know the application name, you can detect whether it is running or not by checking the size of the array containing all AppDescriptors that actually run this application.

int codeModuleHandle = CodeModuleManager.getModuleHandle(applicationPackageName);

if (codeModuleHandle != 0) {
ApplicationDescriptor[] apDes = CodeModuleManager.getApplicationDescriptors(codeModuleHandle);
}

You can imagine a code to get all installed applications and then check

Leave a Comment

Your email address will not be published.