Namespaces
Variants
Actions
Revision as of 14:42, 24 June 2011 by hamishwillee (Talk | contribs)

Avoid reserved IDs in Symbian resource file enumerations (Known Issue)

Jump to: navigation, search

Template:KBKI

Article Metadata

Compatibility
Platform(s): S60 (all)

Article
Created: User:Technical writer 1 (April 7, 2005, updated October 14, 2008)
Last edited: hamishwillee (24 Jun 2011)


Overview

Menu item command IDs and dialog item ID values of 0 will cause problems which may be hard to identify and debug.


Detailed description

Menu item (RESOURCE MENU_ITEM) command IDs and dialog item (RESOURCE DLG_LINE) will cause problems which may be hard to identify and debug if 0 is used as the ID value.


Solution

Always use a non-zero value for MENU_ITEM command IDs, because 0 is reserved for the EEikCmdCanceled command.

Similarly, a dialog's item (DLG_LINE) IDs must be non-zero. Dialog items with a zero ID will result in "Eikon-Dialog 3" panic, where 3 is listed as EEikDialogPanicFocusableLineWithIdZero.

Typically, applications define resource ID values as enumerations and a common mistake is to begin the enumeration from 0 (default), which leads to these hard-to-identify problems.

74 page views in the last 30 days.
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved