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

Native Development

Posts: 95
Registered: ‎02-23-2011
My Device: Z10 STL100-1
My Carrier: IM3

LED class not recgonized by cpp

I'm trying to create a LED object in my app, but for some reason the LED and LEDColor classes are not recognized and are not available for Ctrl+space completion, so I can't see what functions are available from the IDE.


For comparison, BatteryInfo class, which uses the same namespace bb::device, is recognized, and is available in Ctrl+Space completion.


In my cpp, I declared these:


#include <bb/device/Led>

#include <bb/device/LedColor>

#include <bb/device/BatteryInfo>

using namespace bb::device;


when I declare "Bat" and press ctrl+space, IDE instantly completes as BatteryInfo


but when I declare "Le" and press ctrl+space, IDE is confused and says nothing is available.


When manually typing Led *ledObject = new Led(); the "Led" part is not highlighted in green, hovering the mouse above it doesn't show anything, while when declaring BatteryInfo* batteryObject = new BatteryInfo;, the "BatteryInfo" part is highlighted in green and hovering above it reveals the class' constructor


What is happening here?

BlackBerry Z10