[android-developers] Recycling of _ID field in SMS Table

2009-11-24 Thread shahzad ahmad
Hi, I've just found out that _ID field is not always unique in SMS table and gets repeated after some days. Is it normal or some bug ? Can someone tell what is threshold before _ID field is repeated. Actually i have implementing a logic thinking that _ID field is always unique in all records

[android-developers] Crashed Service not restarting

2009-11-21 Thread shahzad ahmad
Hi, I'm just investing how crashed services are restarted. I've developed a simple service and use a taskkiller from market place to kill the application. Following are the logs after application is killed Uninstalling the process test.sys Force removing process ProcessRecord{432d6ad0

[android-developers] Re: Crashed Service not restarting

2009-11-21 Thread shahzad ahmad
I've put some debug prints in onCreate method but they are also not printed which means service is never restarted. Any help ? On Sun, Nov 22, 2009 at 1:53 PM, shahzad ahmad shahzad.s.ah...@gmail.comwrote: Hi, I'm just investing how crashed services are restarted. I've developed a simple

[android-developers] Re: Crashed Service not restarting

2009-11-21 Thread shahzad ahmad
just wanted to tell that the service is started with alarmmanager using setrepeating method. is this the reason for service not restarting ? On Sun, Nov 22, 2009 at 2:03 PM, shahzad ahmad shahzad.s.ah...@gmail.comwrote: I've put some debug prints in onCreate method but they are also not printed

[android-developers] Re: Crashed Service not restarting

2009-11-21 Thread shahzad ahmad
just tested it with startService but still service is not restarting even though system is displaying scheduling restart of crahsed service On Sun, Nov 22, 2009 at 2:25 PM, shahzad ahmad shahzad.s.ah...@gmail.comwrote: just wanted to tell that the service is started with alarmmanager using

[android-developers] Re: Re-Register PhoneStateListener if application crashed

2009-11-18 Thread shahzad ahmad
Any help ? On Wed, Nov 18, 2009 at 1:43 PM, shahzad ahmad shahzad.s.ah...@gmail.comwrote: Hi, i've registered a PhoneStateListener in BOOT_COMPLETED receiver by using following call: tm.listen(new TestCallStateListener(), PhoneStateListener.LISTEN_CALL_STATE); If the application

[android-developers] Re-Register PhoneStateListener if application crashed

2009-11-17 Thread shahzad ahmad
Hi, i've registered a PhoneStateListener in BOOT_COMPLETED receiver by using following call: tm.listen(new TestCallStateListener(), PhoneStateListener.LISTEN_CALL_STATE); If the application crashes then system automatically unregisters the PhoneStateListener. Is there any mechanism of

Re: [android-developers] Re: How do I programatically and permenantly remove an icon from the launcher

2009-11-12 Thread shahzad ahmad
But an application should be able to use setComponentEnabledSetting on it's own activities or other components.Suppose an application has 2 launcher panel activities but after getting user data , it disables one of activities so that it is not shown in launcher panel again. i think such type of

Re: [android-developers] Re: How do I programatically and permenantly remove an icon from the launcher

2009-11-11 Thread shahzad ahmad
Were you able to remove the activity icon from launcher panel? On Thu, Jun 18, 2009 at 10:29 AM, erictcrook erictcr...@gmail.com wrote: Ok, so, I am unable to use setComponentEnable. I apologize for the long post, I am trying to include all the helpful info here. ComponentName

[android-developers] Why activity Icon is not removed from launcher

2009-11-11 Thread shahzad ahmad
hi, I'm trying to remove activity icon from launcher panel. I'm using firmware 1.5. But nothing seems to work. I'm not receiving any error but activity icon is not removed. Following is the code public class HelloActivity extends Activity { public void onCreate(Bundle savedInstanceState) {

[android-developers] Re: end dialer activity

2009-10-12 Thread shahzad ahmad
idea to solve it. Regards, On Oct 12, 3:53 am, shahzad ahmad shahzad.s.ah...@gmail.com wrote: Hi, I have started dialer activity with code Intent myIntent = new Intent(Intent.ACTION_CALL, Uri.parse(createTelUrl(1234567))); startActivityForResult(myIntent

[android-developers] end dialer activity

2009-10-11 Thread shahzad ahmad
Hi, I have started dialer activity with code Intent myIntent = new Intent(Intent.ACTION_CALL, Uri.parse(createTelUrl(1234567))); startActivityForResult(myIntent); Is there a way to stop the dialer activity from same code.? Logically it should be possible as i started it and i

[android-developers] SocketException: The system call was cancelled

2009-10-08 Thread shahzad ahmad
Hi, My application runs as daemon and uploads/downloads data after fixed time intervals. I'm using HTC dream with firmware version 1.1. When phone is locked/sleep mode then after some time i start getting following error while reading or writing to socket. I checked the network status by using

[android-developers] Strange behavior

2009-10-04 Thread shahzad ahmad
Hi, I've developed an application which has a service and boot completed receiver. The boot completed receiver schedules the service to be executed after every 7 minutes. The boot completed receiver saves its context in a public static variable which is then accessed by service whenever it is

[android-developers] Re: Strange behavior

2009-10-04 Thread shahzad ahmad
MyService was about to be scheduled but system delayed it ? On Sun, Oct 4, 2009 at 12:37 PM, shahzad ahmad shahzad.s.ah...@gmail.comwrote: Hi, I've developed an application which has a service and boot completed receiver. The boot completed receiver schedules the service to be executed after

[android-developers] Re: Strange behavior

2009-10-04 Thread shahzad ahmad
and after that application never work ? But in normal case why above message is not displayed and scheduled service works properly? On Sun, Oct 4, 2009 at 1:08 PM, shahzad ahmad shahzad.s.ah...@gmail.comwrote: When the android marketplace was opened on android phone following line was being

[android-developers] problem in deleting Call Log

2009-02-18 Thread shahzad ahmad
Hi, I can easily delete the whole call log with following code getContentResolver().delete(CallLog.Calls.CONTENT_URI,null,null); I can query a particular call log with following code delUri = Uri.withAppendedPath(CallLog.Calls.CONTENT_URI, 2); Cursor cursor =

[android-developers] Re: problem in deleting Call Log

2009-02-18 Thread shahzad ahmad
I'm using SDK 1.0 r2 . This fucntion cursor.deleteRow is deprecated in latest SDK On Wed, Feb 18, 2009 at 6:49 PM, Chandra Mouli chandra...@gmail.com wrote: Try cursor.deleteRow() on the cursor you got from query. On Wed, Feb 18, 2009 at 7:09 PM, shahzad ahmad shahzad.s.ah

[android-developers] custom cleanup on application uninstall

2009-02-05 Thread shahzad ahmad
Is there any mechanism in android to perform post uninstall functions ? Are there any functions which an application can override to perform custom cleanup when it is being uninstalled ? Actually i want to delete some application specific files on uninstall thanks, shahzad

[android-developers] how to remove application specific data

2009-02-04 Thread shahzad ahmad
When an application is installed , it preserves the data of previously installed application . Is there any way to completely wipe out the previous application on fresh install ? Is there any registry or some location where an application can store data and it gets automatically wiped out when

[android-developers] how to completely wipe out the application data

2009-02-04 Thread shahzad ahmad
I'm developing an application which downloads a file from FTP server. The code first checks if file is present on local system . If it is not present on local system then it downloads it from FTP server. Application must download file from FTP server when it executes first time after getting

[android-developers] create a file while installing the apk

2009-02-04 Thread shahzad ahmad
I want my application to read configurations from a file . Is it possible to copy the default configuration file in apk and get it copied to file system when apk is installed ? thanks, shahzad --~--~-~--~~~---~--~~ You received this message because you are

[android-developers] Re: how to completely wipe out the application data

2009-02-04 Thread shahzad ahmad
thanks murphy for your reply.Suppose user downloads the same version of application again then metadata will not help much.There should be some way out everything when an application is uninstalled On Wed, Feb 4, 2009 at 7:34 PM, Mark Murphy mmur...@commonsware.com wrote: shahzad ahmad wrote

[android-developers] Re: DEVICE_POWER permission denied for using goToSleep

2009-02-03 Thread shahzad ahmad
Did u find a way to lock the phone ? On Fri, Jan 30, 2009 at 3:31 PM, mnj manojgopa...@gmail.com wrote: Yes this permission is set in androidmanifest On Jan 29, 5:10 pm, Phill Midwinter ph...@grantmidwinter.com wrote: Is it set in the androidmanifest? 2009/1/29 mnj

[android-developers] How to Lock the phone by application

2009-02-03 Thread shahzad ahmad
Hi, I'm trying to lock the phone through my application .I'm using following code PowerManager pm = (PowerManager)context.getSystemService(Context.POWER_SERVICE); pm.goToSleep(16); I've added following permission to AndroiManifest.xml file uses-permission

[android-developers] Re: deleting whole call log

2008-12-19 Thread shahzad ahmad
any help ? On Thu, Dec 18, 2008 at 2:44 PM, shaz shahzad.s.ah...@gmail.com wrote: I'm trying the whole call log using following code int deleted_rows = cur_context.getContentResolver().delete (CallLog.Calls.CONTENT_URI, null,null); The deletion is successful and whole call log is emptied