Namespaces

Variants
Actions

Please note that as of October 24, 2014, the Nokia Developer Wiki will no longer be accepting user contributions, including new entries, edits and comments, as we begin transitioning to our new home, in the Windows Phone Development Wiki. We plan to move over the majority of the existing entries over the next few weeks. Thanks for all your past and future contributions.

CEikonEnv::Static()-CreateBitmapL() leaves with the error code -1001

From Wiki
Jump to: navigation, search



Article Metadata
Compatibility
Platform(s): S60 1st Edition
S60 2nd Edition
S60 2nd Edition (initial release)
S60 1st Edition
Article
Created: User:Technical writer 2 (08 Sep 2003)
Last edited: hamishwillee (14 Jun 2012)

Overview

CEikonEnv::Static()-CreateBitmapL() leaves with the error code -1001

Description

When trying to use CEikonEnv::Static()->CreateBitmapL() and opening the file fails, the function leaves always with the error code -1001 regardless of the reason of the error (for example,  "file not found" or "out of memory"). How can I find out whether the error was "file not found" or something else?

Solution

If the reason for the file system error is needed, the CWsBitmap::Load() function can be used instead of CreateBitmapL(). It returns system-wide error codes in case of an error. CEikonEnv uses the CWsBitmap::Load() function to load a bitmap but leaves in case of an error. The idea behind the leave is to provide an error text using an error resolution API. There is a difference in the filename parameter of Load() and CreateBitmapL() functions. The former can only use absolute filenames.

This page was last modified on 14 June 2012, at 04:27.
23 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.

 

Thank you!

We appreciate your feedback.

×