Friday, October 31, 2008

Getting the incoming call's phone number

Getting the incoming call's phone number in Blackberry

If your application runs in background and if u want to display phone number during incoming call just implement this code in abstract method.

PhoneCall callInfo = Phone.getActiveCall();
if ( callInfo != null) {
Telephone = callInfo.getDisplayPhoneNumber();
UiApplication.getUiApplication().invokeLater(
new Runnable() {
public void run() {
Status.show("incoming from: "+Telephone);
}
}
);
}

Pausing the application for 1 second in Symbian

Pausing the Symbian app for 1 sec

TRequestStatus timerStatus;
RTimer timer;
timer.CreateLocal();
timer.After(timerStatus,1000000);
User::WaitForRequest(timerStatus);
timer.Close();

This article applies to Symbian and devices P800, P802, P900, P908, P910, M600, P990, W950



Start-up application in Blackberry

Start-up application in Blackberry

To have an application run on startup in Blackberry, right-click the project in the BlackBerry JDE and select Properties. Click the Application tab, and check the Auto-run on Startup check box. If you want your application to run in the background, and not show up on the ribbon at all, check the System Module check box.