Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
New Developer
JavaMEUser
Posts: 55
Registered: ‎04-07-2009
My Device: Not Specified

Application version shows 'unknown' after installing app programmatically using CodeModuleManager

Hi,

 

I use CodeModuleManager methods to automatically upgrade my app.  The installation completes successfully but I see the issues below.

 

1.    The version shown in 'Advanced options - Applications"  is 'unknown' instead of of the actual version.    I can see the correct version when the app is pushed to the device from BES.

 

2.    After installation completes, the CodeModuleManager.sResetRequired  flag is never true.

 

3.  Turning off the device and turning it on doesn't show the newly installed app.  I still see the old one.  I have to remove the battery from the device and put it back to see the new version of the app. 

 

Any ideas ?

 

Thanks.

Please use plain text.
Developer
Posts: 1,474
Registered: ‎04-14-2009
My Device: Not Specified

Re: Application version shows 'unknown' after installing app programmatically using CodeModuleManage

1. You need to use the CodeModuleGroupManager/CodeModuleGroup API to create a code module group, which is what is shown in the Applications screen. A code module group is simply metadata, that aggregates a number of modules, their dependencies, version number, vendor and so forth.

 

2. CodeModuleManager.isResetRequired might be false because no reboot is actually required. This might be the case when you install modules from scratch, without deleting or overwriting existing modules. In the case of very simple modules, even overwriting the modules might not require a reboot.

 

Also, isResetRequired might return false if it's invoked by a process other than the process that invoked the CodeModuleManager API to perform the changes.

 

3. Turning off simply means suspend. Cold-reboot (ALT(left shift) + CAP(right shift) + DEL(backspace) or pulling the battery) is a proper reboot.

Please use plain text.
New Developer
JavaMEUser
Posts: 55
Registered: ‎04-07-2009
My Device: Not Specified

Re: Application version shows 'unknown' after installing app programmatically using CodeModuleManage

1. Can you provide an example for this one.

 

2. In my case I am overwriting an existing module.  So shouldn't the isResetRequired flag be true.?

 

3.  So the only option is proper reboot after an install, in order to use the upgraded app ?  

Please use plain text.
Administrator
MSohm
Posts: 14,362
Registered: ‎07-09-2008
My Device: BlackBerry Z30, BlackBerry PlayBook
My Carrier: Bell

Re: Application version shows 'unknown' after installing app programmatically using CodeModuleManage

Have a look at this example:

 

How to - Programmatically install and upgrade applications
Article Number: DB-00763

http://www.blackberry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800332/800620/How_to_...

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker
Please use plain text.