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

Testing and Deployment

New Contributor
Posts: 2
Registered: ‎11-11-2011
My Device: All BlackBerry Models
My Carrier: N/A
Accepted Solution

Error: A module with that name already exists

[ Edited ]



I work for a company that delivers mobile content to handsets and have come across a problem when delivering Jad/Jar combinations to BlackBerry handsets. For the most part, the files we delivery are Jad/Cod files, which we have no issues with.


The first problem we had is the Jad files we received from our suppliers were referencing Cod files which we were not sent; we were only sent the Jar file. We removed all of the RIM-COD... lines from the Jad file and the problem was resolved. On delivery, the MIDLET-JAR-URL is dynamically altered to point to a page on our site which delivers the content, as explained below.


However, when we tried to install two different applications (both Jad/Jar combinations) to a handset, we received the error message: "[App2] contains a module called [WebpageName]. A module with that name already exists in the [App1] application. If you proceed, [App1] will be replaced by [App2]"


We deliver our content by streaming out valid requests from a single web page. Unique QueryString parameters determine which files are delivered to ensure our content is secure. The [WebpageName] in the Error is the name of the webpage that all files are delivered from, ie: http://www.someurl.com/[WebpageName].aspx?foo=bar&this=that


This is causing us some problems when our customers try to download multiple of these applications/games.


I have looked at the following article, which unfortunately did not help:



I'd be grateful for any suggestions.



New Contributor
Posts: 2
Registered: ‎11-11-2011
My Device: All BlackBerry Models
My Carrier: N/A

Re: Error: A module with that name already exists

I had to create a work-around for the problem. I thought I'd post it in case it helps anyone else:


In IIS, I created a Custom 404 error which redirects to the [WebpageName] page. I then used the filename of the Jar file to create the URL in the Jad so the module name is taken from this, which relates to the individual application.


Example: The MIDLET-JAR-URL line in the Jad is changed:


From: http://www.someurl.com/[WebpageName].aspx?foo=bar&this=that

To: http://www.someurl.com/[FileName].app?foo=bar&this=that


By default I replace the extension to .app so that it is not a recognised file type in IIS.


Hope this helps someone else.