Problem: Received an OutOfMemory error on the BlackBerry simulator after inserting a graphic image, saving, and submitPending in the client.
Explanation: Assuming the mobile business object (MBO) is set properly with a single binary attribute, this can mean the size of the binary attribute is not sufficient. You may need to expand its size.
Solution: Reset the simulator default heap size to a larger value. You may need to experiment with the BlackBerry simulator you are using. For example, you might develop guidelines such as these after experimenting with a BlackBerry 9550 simulator:
- If you set the simulator heap size to 100MB – the suggested size of the binary attribute is 2.5MB. Beyond that size you will probably see an OutOfMemory error in the client.
- If you set the simulator heap size to 256MB – the suggested size of the binary attribute is 6MB. Beyond that size you will probably see an OutOfMemory error in the client.
If an MBO has more than two binary attributes, Sybase
recommends that their combined size not exceed the limit. The OutOfMemory error might
not occur if you exceed the limit, but it is a suggested guideline to prevent exceeding
the limit.