hie ich benutze jde 4.5 möchte die Kamera über meine App verwenden. Ich schreibe den Code und bekomme Runtime Exception Pushmodelscreen von nicht Ereignis Thread getarnt sagen Sie mir, was das Problem darin?Problem beim Starten der Kamera?
public void Start Kamera()
{
try {
// Create a player for the Blackberry's camera
Player player= Manager.createPlayer("capture://video");
// Set the player to the REALIZED state (see Player javadoc)
player.realize();
// Grab the video control and set it to the current display
_videoControl = (VideoControl)player.getControl("VideoControl");
if (_videoControl != null)
{
// Create the video field as a GUI primitive (as opposed to a
// direct video, which can only be used on platforms with
// LCDUI support.)
_videoField = (Field) _videoControl.initDisplayMode (VideoControl.USE_GUI_PRIMITIVE, "net.rim.device.api.ui.Field");
_videoControl.setDisplayFullScreen(true);
_videoControl.setVisible(true);
}
player.start();
if(_videoField!=null)
{
add(_videoField);
}
} catch (Exception e) { // TODO: handle Ausnahme Dialog.alert (e.getMessage()); } } `
thnaks alot Amit
'Pushmodelscreen von non event thread' Dieser Fehler tritt normalerweise auf, wenn ein Popup-Bildschirm oder' Dialog.alert' angezeigt werden muss, bevor ein Bildschirm gedrückt wird. – Prasham