[android-developers] What is a .db-journal file in device?
to dear all Android developers, Does anyone know what exactly a file is database name.db-journal under the /data/data/packages/databases ? I created a database by SQLiteOpenHelper, and wrote something into it for application storage. However I found that there is no data in the database name.db file, then appears a strange file database name.db-journal. I'm wonder whether this file was created by lock of database? If it was, does anyone know how to force the lock released even if the lock was not created by me? Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Cannot process file I/O in InstrumentationTest?
to dear all Android developers, Is the file I/O operations during InstrumentationTest not really written back (aka. committed) to the device storage? Recently I was working on the InstrumentationTest to verify my own applications, however it always shows no data in the local preference and databases of my application (which the data is written in an instrumentation test). I tried to write and read both in either instrumentation test or manually, and it works fine. However, it always fails in the case that either write first in instrumentation test then read later in manually, or manually write and automatically read. So, is this true that the file I/O operations (like preference, database, and content providers) not actually executed during an Instrumentation Test? Thanks for any help :-) Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] What would cause a DeadObjectException?
to dear all Android developers and fans, Does anyone ever meet a android.os.DeadObjectException thrown by a remote service in Android? The problem I met is, the transact method in the service binder interface threw this exception to me. I wrote a remote service, and called it through the service binder. However, in the line of the binder interface (which is generated automatically AIDL interface) mRemote.transact(Stub.TRANSACTION_open, _data, _reply, 0);, it threw a android.os.DeadObjectException to me. I have read the definition of DeadObjectException, it says this exception means The object you are calling has died, because its hosting process no longer exists.. However, I checked this with my DDMS, and it showed the process of the remote service still exists. So, is there any other possible reason to make this exception happened? or could someone here tell me how to avoid this exception? Thanks for all your kind. Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: xmlpullparser don't write in xml?
to dear winger, What's this? an AndroidManifest.xml or a Preference file? If it's a Preference, you should edit it through the PreferenceEditor object. If it is an AndroidManifest.xml file, you can't modify it in runtime, you should modify it with your code editor. Best regards On 6月26日, 上午10時17分, brilliant winger stw...@gmail.com wrote: I have one question. I would like to chage attributevalue. ex... android:codes = 1 to android:codes=2 How ? well. I use other parser? plz --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Does Android not support old SSLv3 protocols?
to dear All, Does anyone meet NoSuchAlgorithmException in SSLContext.getInstance (SSLv3) method? I found Android may close the downward support of old SSL protocols, and keep the latest TLS connections only. Is this true that SSLv3 is not supported in Android? Could anyone provide some information to confirm this? Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Why all mails were turned to unread?
Does anyone ever notice that the mail client (POP3) on Android will turn all the mails' status from read into unread after a Force Close event happened? I found this when I survey whether Android could open a meeting request message. When I opened the meeting.ics attachment which includes the meeting detail, it threw an error message and ask me to force close. After the error event, I went back to my INBOX folder, and after a short period, OOPS, all the mails are changed into unread status. Is this a normal behavior? or did I crush my G1? Pleas tell me I didn't spoil it... Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How to get the UTC bias from TimeZone information?
OK, I found a simple solution here, To get the UTC TimeZone of the phone device sets you will need the codes below: // retrieve the time information from the system and parse into a Time object Time mSavedTime = new Time(); long now = System.currentTimeMillis(); mSavedTime.set(now); // parse the timezone information from the Time object TimeZone mMyTimeZone = TimeZone.getTimeZone(mSavedTime.timezone); // transfer the long TimeZone offset into hours unit int utc_bias = (mMyTimeZone.getRawOffset() / 360); // take daylight saving into consideration, however we need the time for now. The year, month and day could get from the Time object Calendar mCal = Calendar.getInstance(mMyTimeZone); mCal.set(/* year */, /* month, notice that starts from 0 to 11 */, /* day */); if(mMyTimeZone.useDaylightTime() mMyTimeZone.inDaylightTime (mCal.getTime())) { utc = utc + (mMyTimeZone.getDSTSavings() / 360); } On 2月19日, 下午3時14分, bw ben.weisb...@gmail.com wrote: I also couldn't find the solution.. A lookup table/database workaround is posted here:http://groups.google.com/group/android-developers/browse_thread/threa... On Jan 22, 9:59 pm, yukinoba ckmagic...@gmail.com wrote: to dear all Android developers, I need to know theUTCbias of my phone to correct theUTCtime information I got from a site. I have read earlier posts and already found the solution to get TimeZone information from the System.currentTimeMillis(); method. However, I need to translate the TimeZone (as like, Asia/Taipei) to theUTCbias that it has to be (as like, UTC+8 or other formats). Does anyone know the actual API solution? I have surveyed android.util.TimeUtils and found nothing to do this. The worst solution may I have is to build a TimeZone/UTC database table to translate this... Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: What will cause SQLiteQueryBuilder.query infinite loop?
Hi all, More information found: The database could be written by the execSQL method, however, it could not be read from the query method. A Write-Only database? that's weird... I open my database with SQLiteDatabaseHelper and SQLiteDatabase as below: mDbHelper = new DatabaseHelper(mCtx); mDb = mDbHelper.getWritableDatabase(); Is it possible that the read-access is locked by the first database? I'm sure that I close my database with mDbHelper.close() after each query... On 2月12日, 下午4時00分, yukinoba ckmagic...@gmail.com wrote: to dear all, I just found a same open problem as the one I met:http://groups.google.com/group/android-developers/browse_thread/threa... Hope this could help Any suggestions and ideas are welcome, Plz :-) Best regards, Nicholas On 2月12日, 下午2時49分, yukinoba ckmagic...@gmail.com wrote: I have a new question for this: Can there have multiple databases created in the same application or service? I have 2 databases, one for query and store the information about phone numbers, and one for the names. However, the ealier one works fine, and the later one stucks in the method and never get rid of that status. So, my question is, does each application / service have been limited to have only one single database? Plz provides any help or suggestion Best regards, Nicholas On 2月12日, 上午9時23分, yukinoba ckmagic...@gmail.com wrote: Could someone give a little bit information about any possible solution or hint? I have searched in this forum and nothing about this topic :-( On 2月11日, 下午6時44分, yukinoba ckmagic...@gmail.com wrote: More information: Most of the data (surname) here are utf-8 encoded, does this cause the error? Could anyone tell me how to push an utf-8 String in the SQL statement? Thanks for any help! :-) Best regards, Nicholas On 2月11日, 下午5時18分, yukinoba ckmagic...@gmail.com wrote: to dear all Android developers, I'm dealing with database operation on Android recently. However, there has a problem troubles me that the query method in SQLiteQueryBuilder infinitely loops and has no return. The operation code is like below: // CODE section --// SQLiteQueryBuilder qb = new SQLiteQueryBuilder(); qb.setTables(TABLE.NAME); qb.setProjectionMap(TABLE.ProjectionMap); qb.appendWhere(TABLE._ID + = + id + AND + TABLE.SURNAME + =' + surname + '); String orderBy = TABLE._ID + ASC; String[] projection = new String[] { TABLE._ID }; mDbHelper = new DatabaseHelper(mCtx); mDb = mDbHelper.getWritableDatabase(); Cursor c = qb.query(mDb, projection, null, null, null, null, orderBy); // CODE section --// However, it stuck in the query and never return back, and there has neither exceptions nor any error messages from the LogCat. Does there any mistake I make in my code? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: What will cause SQLiteQueryBuilder.query infinite loop?
To dear all, I found that when you use _id column as the projection map and the order-by value, the query will stuck and never return. However, there has another problem still blocks me to return back from the query method. Please, I need more information and help. Sincerely, Nicholas On 2月12日, 下午4時15分, yukinoba ckmagic...@gmail.com wrote: Hi all, More information found: The database could be written by the execSQL method, however, it could not be read from the query method. A Write-Only database? that's weird... I open my database with SQLiteDatabaseHelper and SQLiteDatabase as below: mDbHelper = new DatabaseHelper(mCtx); mDb = mDbHelper.getWritableDatabase(); Is it possible that the read-access is locked by the first database? I'm sure that I close my database with mDbHelper.close() after each query... On 2月12日, 下午4時00分, yukinoba ckmagic...@gmail.com wrote: to dear all, I just found a same open problem as the one I met:http://groups.google.com/group/android-developers/browse_thread/threa... Hope this could help Any suggestions and ideas are welcome, Plz :-) Best regards, Nicholas On 2月12日, 下午2時49分, yukinoba ckmagic...@gmail.com wrote: I have a new question for this: Can there have multiple databases created in the same application or service? I have 2 databases, one for query and store the information about phone numbers, and one for the names. However, the ealier one works fine, and the later one stucks in the method and never get rid of that status. So, my question is, does each application / service have been limited to have only one single database? Plz provides any help or suggestion Best regards, Nicholas On 2月12日, 上午9時23分, yukinoba ckmagic...@gmail.com wrote: Could someone give a little bit information about any possible solution or hint? I have searched in this forum and nothing about this topic :-( On 2月11日, 下午6時44分, yukinoba ckmagic...@gmail.com wrote: More information: Most of the data (surname) here are utf-8 encoded, does this cause the error? Could anyone tell me how to push an utf-8 String in the SQL statement? Thanks for any help! :-) Best regards, Nicholas On 2月11日, 下午5時18分, yukinoba ckmagic...@gmail.com wrote: to dear all Android developers, I'm dealing with database operation on Android recently. However, there has a problem troubles me that the query method in SQLiteQueryBuilder infinitely loops and has no return. The operation code is like below: // CODE section --// SQLiteQueryBuilder qb = new SQLiteQueryBuilder(); qb.setTables(TABLE.NAME); qb.setProjectionMap(TABLE.ProjectionMap); qb.appendWhere(TABLE._ID + = + id + AND + TABLE.SURNAME + =' + surname + '); String orderBy = TABLE._ID + ASC; String[] projection = new String[] { TABLE._ID }; mDbHelper = new DatabaseHelper(mCtx); mDb = mDbHelper.getWritableDatabase(); Cursor c = qb.query(mDb, projection, null, null, null, null, orderBy); // CODE section --// However, it stuck in the query and never return back, and there has neither exceptions nor any error messages from the LogCat. Does there any mistake I make in my code? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: What will cause SQLiteQueryBuilder.query infinite loop?
More information: The _id column brings no trouble as an ORDER BY argument, but can not exist in the projection map. The reason is still unknown. Needs help, please. Sincerely, Nicholas On 2月13日, 上午10時32分, yukinoba ckmagic...@gmail.com wrote: To dear all, I found that when you use _id column as the projection map and the order-by value, the query will stuck and never return. However, there has another problem still blocks me to return back from the query method. Please, I need more information and help. Sincerely, Nicholas On 2月12日, 下午4時15分, yukinoba ckmagic...@gmail.com wrote: Hi all, More information found: The database could be written by the execSQL method, however, it could not be read from the query method. A Write-Only database? that's weird... I open my database with SQLiteDatabaseHelper and SQLiteDatabase as below: mDbHelper = new DatabaseHelper(mCtx); mDb = mDbHelper.getWritableDatabase(); Is it possible that the read-access is locked by the first database? I'm sure that I close my database with mDbHelper.close() after each query... On 2月12日, 下午4時00分, yukinoba ckmagic...@gmail.com wrote: to dear all, I just found a same open problem as the one I met:http://groups.google.com/group/android-developers/browse_thread/threa... Hope this could help Any suggestions and ideas are welcome, Plz :-) Best regards, Nicholas On 2月12日, 下午2時49分, yukinoba ckmagic...@gmail.com wrote: I have a new question for this: Can there have multiple databases created in the same application or service? I have 2 databases, one for query and store the information about phone numbers, and one for the names. However, the ealier one works fine, and the later one stucks in the method and never get rid of that status. So, my question is, does each application / service have been limited to have only one single database? Plz provides any help or suggestion Best regards, Nicholas On 2月12日, 上午9時23分, yukinoba ckmagic...@gmail.com wrote: Could someone give a little bit information about any possible solution or hint? I have searched in this forum and nothing about this topic :-( On 2月11日, 下午6時44分, yukinoba ckmagic...@gmail.com wrote: More information: Most of the data (surname) here are utf-8 encoded, does this cause the error? Could anyone tell me how to push an utf-8 String in the SQL statement? Thanks for any help! :-) Best regards, Nicholas On 2月11日, 下午5時18分, yukinoba ckmagic...@gmail.com wrote: to dear all Android developers, I'm dealing with database operation on Android recently. However, there has a problem troubles me that the query method in SQLiteQueryBuilder infinitely loops and has no return. The operation code is like below: // CODE section --// SQLiteQueryBuilder qb = new SQLiteQueryBuilder(); qb.setTables(TABLE.NAME); qb.setProjectionMap(TABLE.ProjectionMap); qb.appendWhere(TABLE._ID + = + id + AND + TABLE.SURNAME + =' + surname + '); String orderBy = TABLE._ID + ASC; String[] projection = new String[] { TABLE._ID }; mDbHelper = new DatabaseHelper(mCtx); mDb = mDbHelper.getWritableDatabase(); Cursor c = qb.query(mDb, projection, null, null, null, null, orderBy); // CODE section --// However, it stuck in the query and never return back, and there has neither exceptions nor any error messages from the LogCat. Does there any mistake I make in my code? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: What will cause SQLiteQueryBuilder.query infinite loop?
OK, let's close this issue. The problem is, the SQLiteDatabaseBuilder.query can not return and just stuck there. The reason is, it can not find a projection mapping of the column TABLE._ID in the TABLE.ProjectionMap which is given into the qb.setProjectionMap method. The solution is, remember to add ProjectionMap.put(_ID, _ID); in your class class TABLE extends BaseColumns even if the column is extended from BaseColumns. You may think its a default column and it should be added automatically into, in fact, not. ISSUE CLOSED Although no one provides any information, still thanks all Android developers. Sincerely, On 2月13日, 上午11時04分, yukinoba ckmagic...@gmail.com wrote: More information: The _id column brings no trouble as an ORDER BY argument, but can not exist in the projection map. The reason is still unknown. Needs help, please. Sincerely, Nicholas On 2月13日, 上午10時32分, yukinoba ckmagic...@gmail.com wrote: To dear all, I found that when you use _id column as the projection map and the order-by value, the query will stuck and never return. However, there has another problem still blocks me to return back from the query method. Please, I need more information and help. Sincerely, Nicholas On 2月12日, 下午4時15分, yukinoba ckmagic...@gmail.com wrote: Hi all, More information found: The database could be written by the execSQL method, however, it could not be read from the query method. A Write-Only database? that's weird... I open my database with SQLiteDatabaseHelper and SQLiteDatabase as below: mDbHelper = new DatabaseHelper(mCtx); mDb = mDbHelper.getWritableDatabase(); Is it possible that the read-access is locked by the first database? I'm sure that I close my database with mDbHelper.close() after each query... On 2月12日, 下午4時00分, yukinoba ckmagic...@gmail.com wrote: to dear all, I just found a same open problem as the one I met:http://groups.google.com/group/android-developers/browse_thread/threa... Hope this could help Any suggestions and ideas are welcome, Plz :-) Best regards, Nicholas On 2月12日, 下午2時49分, yukinoba ckmagic...@gmail.com wrote: I have a new question for this: Can there have multiple databases created in the same application or service? I have 2 databases, one for query and store the information about phone numbers, and one for the names. However, the ealier one works fine, and the later one stucks in the method and never get rid of that status. So, my question is, does each application / service have been limited to have only one single database? Plz provides any help or suggestion Best regards, Nicholas On 2月12日, 上午9時23分, yukinoba ckmagic...@gmail.com wrote: Could someone give a little bit information about any possible solution or hint? I have searched in this forum and nothing about this topic :-( On 2月11日, 下午6時44分, yukinoba ckmagic...@gmail.com wrote: More information: Most of the data (surname) here are utf-8 encoded, does this cause the error? Could anyone tell me how to push an utf-8 String in the SQL statement? Thanks for any help! :-) Best regards, Nicholas On 2月11日, 下午5時18分, yukinoba ckmagic...@gmail.com wrote: to dear all Android developers, I'm dealing with database operation on Android recently. However, there has a problem troubles me that the query method in SQLiteQueryBuilder infinitely loops and has no return. The operation code is like below: // CODE section --// SQLiteQueryBuilder qb = new SQLiteQueryBuilder(); qb.setTables(TABLE.NAME); qb.setProjectionMap(TABLE.ProjectionMap); qb.appendWhere(TABLE._ID + = + id + AND + TABLE.SURNAME + =' + surname + '); String orderBy = TABLE._ID + ASC; String[] projection = new String[] { TABLE._ID }; mDbHelper = new DatabaseHelper(mCtx); mDb = mDbHelper.getWritableDatabase(); Cursor c = qb.query(mDb, projection, null, null, null, null, orderBy); // CODE section --// However, it stuck in the query and never return back, and there has neither exceptions nor any error messages from the LogCat. Does there any mistake I make in my code? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] What will cause SQLiteQueryBuilder.query infinite loop?
to dear all Android developers, I'm dealing with database operation on Android recently. However, there has a problem troubles me that the query method in SQLiteQueryBuilder infinitely loops and has no return. The operation code is like below: // CODE section --// SQLiteQueryBuilder qb = new SQLiteQueryBuilder(); qb.setTables(TABLE.NAME); qb.setProjectionMap(TABLE.ProjectionMap); qb.appendWhere(TABLE._ID + = + id + AND + TABLE.SURNAME + =' + surname + '); String orderBy = TABLE._ID + ASC; String[] projection = new String[] { TABLE._ID }; mDbHelper = new DatabaseHelper(mCtx); mDb = mDbHelper.getWritableDatabase(); Cursor c = qb.query(mDb, projection, null, null, null, null, orderBy); // CODE section --// However, it stuck in the query and never return back, and there has neither exceptions nor any error messages from the LogCat. Does there any mistake I make in my code? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: What will cause SQLiteQueryBuilder.query infinite loop?
Could someone give a little bit information about any possible solution or hint? I have searched in this forum and nothing about this topic :-( On 2月11日, 下午6時44分, yukinoba ckmagic...@gmail.com wrote: More information: Most of the data (surname) here are utf-8 encoded, does this cause the error? Could anyone tell me how to push an utf-8 String in the SQL statement? Thanks for any help! :-) Best regards, Nicholas On 2月11日, 下午5時18分, yukinoba ckmagic...@gmail.com wrote: to dear all Android developers, I'm dealing with database operation on Android recently. However, there has a problem troubles me that the query method in SQLiteQueryBuilder infinitely loops and has no return. The operation code is like below: // CODE section --// SQLiteQueryBuilder qb = new SQLiteQueryBuilder(); qb.setTables(TABLE.NAME); qb.setProjectionMap(TABLE.ProjectionMap); qb.appendWhere(TABLE._ID + = + id + AND + TABLE.SURNAME + =' + surname + '); String orderBy = TABLE._ID + ASC; String[] projection = new String[] { TABLE._ID }; mDbHelper = new DatabaseHelper(mCtx); mDb = mDbHelper.getWritableDatabase(); Cursor c = qb.query(mDb, projection, null, null, null, null, orderBy); // CODE section --// However, it stuck in the query and never return back, and there has neither exceptions nor any error messages from the LogCat. Does there any mistake I make in my code? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: What will cause SQLiteQueryBuilder.query infinite loop?
I have a new question for this: Can there have multiple databases created in the same application or service? I have 2 databases, one for query and store the information about phone numbers, and one for the names. However, the ealier one works fine, and the later one stucks in the method and never get rid of that status. So, my question is, does each application / service have been limited to have only one single database? Plz provides any help or suggestion Best regards, Nicholas On 2月12日, 上午9時23分, yukinoba ckmagic...@gmail.com wrote: Could someone give a little bit information about any possible solution or hint? I have searched in this forum and nothing about this topic :-( On 2月11日, 下午6時44分, yukinoba ckmagic...@gmail.com wrote: More information: Most of the data (surname) here are utf-8 encoded, does this cause the error? Could anyone tell me how to push an utf-8 String in the SQL statement? Thanks for any help! :-) Best regards, Nicholas On 2月11日, 下午5時18分, yukinoba ckmagic...@gmail.com wrote: to dear all Android developers, I'm dealing with database operation on Android recently. However, there has a problem troubles me that the query method in SQLiteQueryBuilder infinitely loops and has no return. The operation code is like below: // CODE section --// SQLiteQueryBuilder qb = new SQLiteQueryBuilder(); qb.setTables(TABLE.NAME); qb.setProjectionMap(TABLE.ProjectionMap); qb.appendWhere(TABLE._ID + = + id + AND + TABLE.SURNAME + =' + surname + '); String orderBy = TABLE._ID + ASC; String[] projection = new String[] { TABLE._ID }; mDbHelper = new DatabaseHelper(mCtx); mDb = mDbHelper.getWritableDatabase(); Cursor c = qb.query(mDb, projection, null, null, null, null, orderBy); // CODE section --// However, it stuck in the query and never return back, and there has neither exceptions nor any error messages from the LogCat. Does there any mistake I make in my code? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] How to get the UTC bias from TimeZone information?
to dear all Android developers, I need to know the UTC bias of my phone to correct the UTC time information I got from a site. I have read earlier posts and already found the solution to get TimeZone information from the System.currentTimeMillis(); method. However, I need to translate the TimeZone (as like, Asia/Taipei) to the UTC bias that it has to be (as like, UTC+8 or other formats). Does anyone know the actual API solution? I have surveyed android.util.TimeUtils and found nothing to do this. The worst solution may I have is to build a TimeZone/UTC database table to translate this... Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Where could I get an ADT 0.9.0?
Hi, Wah Sorry for late reply to your problem. First, you have to confirm the eclipse version you downloaded is the latest version and has PDE feature (the feature list could be found in the Eclipse website). For better insurance, you shall download the full package Eclipse. Second, the build script you should run is build_server.sh rather than build_plugins.sh. Since I have never tried to build my own ADT with the build_plugins.sh, I can't explain what kind of trouble you met. However, if you still fail over and over again, just tell me. I could mail you my own built ADT zip file to you. Best regards, Nicholas On 1月1日, 上午5時59分, Wah mobic...@gmail.com wrote: Yukinoba: I tried to build using build_server.sh with the following set of commands and failed: setenv ECLIPSE_HOME /usr/local/installed/eclipse cd ~/mydroid/development/tools/eclipse/scripts ./build_plugins.sh -i -d ~/android-plugin The error I got is: = ... [javac] [completed /home/haha/mydroid/development/tools/eclipse/ plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/ views/ThreadView.java - #17/17] [javac] [17 units compiled] [javac] [3 .class files generated] [javac] LogPanel cannot be resolved to a type [javac] -- [javac] 225. ERROR in /home/haha/mydroid/development/tools/eclipse/ plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/ views/LogCatView.java (at line 248) [javac] mLogPanel = new LogPanel(loader, colors, new FilterStorage (), LogPanel.FILTER_MANUAL); [javac] ^ [javac] LogPanel cannot be resolved to a type [javac] -- [javac] 226. ERROR in /home/haha/mydroid/development/tools/eclipse/ plugins/com.android.ide.eclipse.ddms/src/com/android/ide/eclipse/ddms/ views/LogCatView.java (at line 248) [javac] mLogPanel = new LogPanel(loader, colors, new FilterStorage (), LogPanel.FILTER_MANUAL); [javac] [javac] LogPanel cannot be resolved to a type ... = Can you help to see what went wrong? Wah On Dec 29, 6:37 pm, yukinoba ckmagic...@gmail.com wrote: to dear Kenny, I have solved this problem by taking a build sequence to theADT source code under the newly released cupcake device code, and thanks for your concern ;-) The newADT(version 0.9.0) is under the /device- code-root/devlopment/tools/eclipse/plugins/ com.android.ide.eclipse.adt, and build the plugin with running the script file build_server.sh under the /device-code-root/devlopment/ tools/eclipse/scripts. P.s. you will need to download an eclipse with PDE functionality, and set $ECLIPSE_HOME to the eclipse root to complete this and thanks for your help again! :-) Best regards, Nicholas On 12月28日, 上午1時41分, Kenny Yu yxw...@gmail.com wrote: I built cupcake, which has been merged to master HEAD. TheADTis quite OK. Can you share more info? Kenny On Dec 26, 11:35 am, yukinoba ckmagic...@gmail.com wrote: To dear all, Does anyone have the cupcake? The SDK in there is not applicable to theADTplugin (Android Development Tools plugin) of Eclipse any more, and Eclipse throws a message told me I should get an updatedADTwith version 0.9.0. However, I tried to build one in the source, and found that the latest version in the cupcake source code is 0.8.1 rather than 0.9.0. So, is there anyone enjoyed their cupcakes with Eclipse? I need aADT 0.9.0 support... Thx for ur help Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How could I know a Service is already started?
to dear Dianne, I need to implement a remote background service and a service controller activity. I want to present an effect which the controller activity could know whether or not this service is already started, and enable / disable the menu button which is used to start / bind / unbind / stop the service. However, the controller activity may be paused, or destoryed. I have tried to write the status in a global variable, and with the activity destoryed, the variable value lost. I also tried to write into a SharedPreference, however, this will be persistent even the emulator shuts down. In the later case, the preference status will mislead the controller activity when the system is up next time. So, I need a way to know whether a specified background service is launched or not even if the controller activity is destroyed and back then. :-) Best regards, Nicholas On 1月6日, 下午3時40分, Dianne Hackborn hack...@android.com wrote: I would strongly recommend against that, it can be quite inefficient. This API is really intended for applications to display a list of running services. If your service is running in the same process as the code wanting to check its state, you can just set a global variable while it is running. Why do you need to do this? On Mon, Jan 5, 2009 at 10:34 PM, yukinoba ckmagic...@gmail.com wrote: Hi all, I have already found out how to get this done. Please refer to the following code: /** * Indicates whether the specified service is already started. This * method queries the activity manager for launched services that can * respond to an binding with an specific service name. * If no existed service is found, this method returns null. * * @param context The context of the activity * @param className The service full name to check for availability. * * @return ComponentName if the service is already existed, NULL otherwise. */ public static ComponentName isServiceExisted(Context context, String className) { ActivityManager activityManager = (ActivityManager) context.getSystemService(ACTIVITY_SERVICE); ListActivityManager.RunningServiceInfo serviceList = activityManager.getRunningServices(Integer.MAX_VALUE); if(!(serviceList.size() 0)) { return null; } for(int i = 0; i serviceList.size(); i++) { RunningServiceInfo serviceInfo = serviceList.get(i); ComponentName serviceName = serviceInfo.service; if(serviceName.getClassName().equals(className)) { return serviceName; } } return null; } Best regards, Nicholas On 1月6日, 上午10時58分, yukinoba ckmagic...@gmail.com wrote: Ummm... does anyone know? have any ideas? On 1月5日, 下午12時05分, yukinoba ckmagic...@gmail.com wrote: To dear all Android developers, Is there a way to check whether a service is already started or not? This issue has been discussed ealier (and much earlier) in April, in the last year, on this forum. http://groups.google.com/group/android-developers/browse_thread/threa. .. However, I wonder that does there have a new solution to this issue rather than using a SharedPreferences to store the service status. Is this functionality to check service is started or not has been added to SDK1.0_r2 or Cupcake branch? Thanks for any help or solutions! :-) Best regards, Nicholas -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support. All such questions should be posted on public forums, where I and others can see and answer them. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How could I know a Service is already started?
to dear Dianne, I see your point. However, when I try to bind the service without BIND_AUTO_CREATE flag, I expect it will return false to me. But the bindService method always returns true. This is a weird behavior for bindService with a flag 0. the code I used is following: isBound = bindService(new Intent(IRemoteService.class.getName()), mConnection, 0); According to the document, this should return false while the service is not running or started, but I got false even if the emulator and the controller activity starts freshly. Does bindService return true when there is a service registered rather than there is a service started? I think I would agree with your point, this could be efficient and safety (since I don't need to expose the full class name for query in the RunningServiceInfo list), but I need a little more help in solving bindService problem. ;-) Best regards, Nicholas On 1月6日, 下午5時42分, Dianne Hackborn hack...@android.com wrote: To monitor the state of a service, I suggest binding to it without the flag to create it. Then you will not cause it to start, but be told when it is created or destroyed via the appropriate callbacks. On Tue, Jan 6, 2009 at 1:24 AM, yukinoba ckmagic...@gmail.com wrote: to dear Dianne, I need to implement a remote background service and a service controller activity. I want to present an effect which the controller activity could know whether or not this service is already started, and enable / disable the menu button which is used to start / bind / unbind / stop the service. However, the controller activity may be paused, or destoryed. I have tried to write the status in a global variable, and with the activity destoryed, the variable value lost. I also tried to write into a SharedPreference, however, this will be persistent even the emulator shuts down. In the later case, the preference status will mislead the controller activity when the system is up next time. So, I need a way to know whether a specified background service is launched or not even if the controller activity is destroyed and back then. :-) Best regards, Nicholas On 1月6日, 下午3時40分, Dianne Hackborn hack...@android.com wrote: I would strongly recommend against that, it can be quite inefficient. This API is really intended for applications to display a list of running services. If your service is running in the same process as the code wanting to check its state, you can just set a global variable while it is running. Why do you need to do this? On Mon, Jan 5, 2009 at 10:34 PM, yukinoba ckmagic...@gmail.com wrote: Hi all, I have already found out how to get this done. Please refer to the following code: /** * Indicates whether the specified service is already started. This * method queries the activity manager for launched services that can * respond to an binding with an specific service name. * If no existed service is found, this method returns null. * * @param context The context of the activity * @param className The service full name to check for availability. * * @return ComponentName if the service is already existed, NULL otherwise. */ public static ComponentName isServiceExisted(Context context, String className) { ActivityManager activityManager = (ActivityManager) context.getSystemService(ACTIVITY_SERVICE); ListActivityManager.RunningServiceInfo serviceList = activityManager.getRunningServices(Integer.MAX_VALUE); if(!(serviceList.size() 0)) { return null; } for(int i = 0; i serviceList.size(); i++) { RunningServiceInfo serviceInfo = serviceList.get(i); ComponentName serviceName = serviceInfo.service; if(serviceName.getClassName().equals(className)) { return serviceName; } } return null; } Best regards, Nicholas On 1月6日, 上午10時58分, yukinoba ckmagic...@gmail.com wrote: Ummm... does anyone know? have any ideas? On 1月5日, 下午12時05分, yukinoba ckmagic...@gmail.com wrote: To dear all Android developers, Is there a way to check whether a service is already started or not? This issue has been discussed ealier (and much earlier) in April, in the last year, on this forum. http://groups.google.com/group/android-developers/browse_thread/threa. .. However, I wonder that does there have a new solution to this issue rather than using a SharedPreferences to store the service status. Is this functionality to check service is started or not has been added to SDK1.0_r2 or Cupcake branch? Thanks for any help
[android-developers] Re: How could I know a Service is already started?
to dear Dianne, I see your point. However, when I try to bind the service without BIND_AUTO_CREATE flag, I expect it will return false to me. But the bindService method always returns true. This is a weird behavior for bindService with a flag 0. the code I used is following: isBound = bindService(new Intent(IRemoteService.class.getName()), mConnection, 0); According to the document, this should return false while the service is not running or started, but I got true even if the emulator and the controller activity starts freshly. Does bindService return true when there is a service registered rather than there is a service started? I think I would agree with your point, this could be efficient and safety (since I don't need to expose the full class name for query in the RunningServiceInfo list), but I need a little more help in solving bindService problem. ;-) Best regards, Nicholas On 1月6日, 下午5時42分, Dianne Hackborn hack...@android.com wrote: To monitor the state of a service, I suggest binding to it without the flag to create it. Then you will not cause it to start, but be told when it is created or destroyed via the appropriate callbacks. On Tue, Jan 6, 2009 at 1:24 AM, yukinoba ckmagic...@gmail.com wrote: to dear Dianne, I need to implement a remote background service and a service controller activity. I want to present an effect which the controller activity could know whether or not this service is already started, and enable / disable the menu button which is used to start / bind / unbind / stop the service. However, the controller activity may be paused, or destoryed. I have tried to write the status in a global variable, and with the activity destoryed, the variable value lost. I also tried to write into a SharedPreference, however, this will be persistent even the emulator shuts down. In the later case, the preference status will mislead the controller activity when the system is up next time. So, I need a way to know whether a specified background service is launched or not even if the controller activity is destroyed and back then. :-) Best regards, Nicholas On 1月6日, 下午3時40分, Dianne Hackborn hack...@android.com wrote: I would strongly recommend against that, it can be quite inefficient. This API is really intended for applications to display a list of running services. If your service is running in the same process as the code wanting to check its state, you can just set a global variable while it is running. Why do you need to do this? On Mon, Jan 5, 2009 at 10:34 PM, yukinoba ckmagic...@gmail.com wrote: Hi all, I have already found out how to get this done. Please refer to the following code: /** * Indicates whether the specified service is already started. This * method queries the activity manager for launched services that can * respond to an binding with an specific service name. * If no existed service is found, this method returns null. * * @param context The context of the activity * @param className The service full name to check for availability. * * @return ComponentName if the service is already existed, NULL otherwise. */ public static ComponentName isServiceExisted(Context context, String className) { ActivityManager activityManager = (ActivityManager) context.getSystemService(ACTIVITY_SERVICE); ListActivityManager.RunningServiceInfo serviceList = activityManager.getRunningServices(Integer.MAX_VALUE); if(!(serviceList.size() 0)) { return null; } for(int i = 0; i serviceList.size(); i++) { RunningServiceInfo serviceInfo = serviceList.get(i); ComponentName serviceName = serviceInfo.service; if(serviceName.getClassName().equals(className)) { return serviceName; } } return null; } Best regards, Nicholas On 1月6日, 上午10時58分, yukinoba ckmagic...@gmail.com wrote: Ummm... does anyone know? have any ideas? On 1月5日, 下午12時05分, yukinoba ckmagic...@gmail.com wrote: To dear all Android developers, Is there a way to check whether a service is already started or not? This issue has been discussed ealier (and much earlier) in April, in the last year, on this forum. http://groups.google.com/group/android-developers/browse_thread/threa. .. However, I wonder that does there have a new solution to this issue rather than using a SharedPreferences to store the service status. Is this functionality to check service is started or not has been added to SDK1.0_r2 or Cupcake branch? Thanks for any help
[android-developers] Re: How could I know a Service is already started?
Hi, I have tried this again with the RemoteServiceBinding example in the ApiDemos example packages. I turned the flag argument to Context.BIND_AUTO_CREATE, Context.BIND_DEBUG_UNBIND, or 0, and found out the return value of bindService is always true. More than this, when I left the RemoteServiceBinding activity, the system shows me an error message about the ServiceConnection object which is passed into the bindService. I have no idea to these cases, could you give a hand to clarify what's the difference between Context.BIND_AUTO_CREATE, Context.BIND_DEBUG_UNBIND, and flag 0? And what kind of behavior will the bindService method have? Best regards, Nicholas On 1月6日, 下午5時42分, Dianne Hackborn hack...@android.com wrote: To monitor the state of a service, I suggest binding to it without the flag to create it. Then you will not cause it to start, but be told when it is created or destroyed via the appropriate callbacks. On Tue, Jan 6, 2009 at 1:24 AM, yukinoba ckmagic...@gmail.com wrote: to dear Dianne, I need to implement a remote background service and a service controller activity. I want to present an effect which the controller activity could know whether or not this service is already started, and enable / disable the menu button which is used to start / bind / unbind / stop the service. However, the controller activity may be paused, or destoryed. I have tried to write the status in a global variable, and with the activity destoryed, the variable value lost. I also tried to write into a SharedPreference, however, this will be persistent even the emulator shuts down. In the later case, the preference status will mislead the controller activity when the system is up next time. So, I need a way to know whether a specified background service is launched or not even if the controller activity is destroyed and back then. :-) Best regards, Nicholas On 1月6日, 下午3時40分, Dianne Hackborn hack...@android.com wrote: I would strongly recommend against that, it can be quite inefficient. This API is really intended for applications to display a list of running services. If your service is running in the same process as the code wanting to check its state, you can just set a global variable while it is running. Why do you need to do this? On Mon, Jan 5, 2009 at 10:34 PM, yukinoba ckmagic...@gmail.com wrote: Hi all, I have already found out how to get this done. Please refer to the following code: /** * Indicates whether the specified service is already started. This * method queries the activity manager for launched services that can * respond to an binding with an specific service name. * If no existed service is found, this method returns null. * * @param context The context of the activity * @param className The service full name to check for availability. * * @return ComponentName if the service is already existed, NULL otherwise. */ public static ComponentName isServiceExisted(Context context, String className) { ActivityManager activityManager = (ActivityManager) context.getSystemService(ACTIVITY_SERVICE); ListActivityManager.RunningServiceInfo serviceList = activityManager.getRunningServices(Integer.MAX_VALUE); if(!(serviceList.size() 0)) { return null; } for(int i = 0; i serviceList.size(); i++) { RunningServiceInfo serviceInfo = serviceList.get(i); ComponentName serviceName = serviceInfo.service; if(serviceName.getClassName().equals(className)) { return serviceName; } } return null; } Best regards, Nicholas On 1月6日, 上午10時58分, yukinoba ckmagic...@gmail.com wrote: Ummm... does anyone know? have any ideas? On 1月5日, 下午12時05分, yukinoba ckmagic...@gmail.com wrote: To dear all Android developers, Is there a way to check whether a service is already started or not? This issue has been discussed ealier (and much earlier) in April, in the last year, on this forum. http://groups.google.com/group/android-developers/browse_thread/threa. .. However, I wonder that does there have a new solution to this issue rather than using a SharedPreferences to store the service status. Is this functionality to check service is started or not has been added to SDK1.0_r2 or Cupcake branch? Thanks for any help or solutions! :-) Best regards, Nicholas -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support. All
[android-developers] Re: How could I know a Service is already started?
Ummm... does anyone know? have any ideas? On 1月5日, 下午12時05分, yukinoba ckmagic...@gmail.com wrote: To dear all Android developers, Is there a way to check whether a service is already started or not? This issue has been discussed ealier (and much earlier) in April, in the last year, on this forum. http://groups.google.com/group/android-developers/browse_thread/threa... However, I wonder that does there have a new solution to this issue rather than using a SharedPreferences to store the service status. Is this functionality to check service is started or not has been added to SDK1.0_r2 or Cupcake branch? Thanks for any help or solutions! :-) Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How could I know a Service is already started?
Hi all, I have already found out how to get this done. Please refer to the following code: /** * Indicates whether the specified service is already started. This * method queries the activity manager for launched services that can * respond to an binding with an specific service name. * If no existed service is found, this method returns null. * * @param context The context of the activity * @param className The service full name to check for availability. * * @return ComponentName if the service is already existed, NULL otherwise. */ public static ComponentName isServiceExisted(Context context, String className) { ActivityManager activityManager = (ActivityManager) context.getSystemService(ACTIVITY_SERVICE); ListActivityManager.RunningServiceInfo serviceList = activityManager.getRunningServices(Integer.MAX_VALUE); if(!(serviceList.size() 0)) { return null; } for(int i = 0; i serviceList.size(); i++) { RunningServiceInfo serviceInfo = serviceList.get(i); ComponentName serviceName = serviceInfo.service; if(serviceName.getClassName().equals(className)) { return serviceName; } } return null; } Best regards, Nicholas On 1月6日, 上午10時58分, yukinoba ckmagic...@gmail.com wrote: Ummm... does anyone know? have any ideas? On 1月5日, 下午12時05分, yukinoba ckmagic...@gmail.com wrote: To dear all Android developers, Is there a way to check whether a service is already started or not? This issue has been discussed ealier (and much earlier) in April, in the last year, on this forum. http://groups.google.com/group/android-developers/browse_thread/threa... However, I wonder that does there have a new solution to this issue rather than using a SharedPreferences to store the service status. Is this functionality to check service is started or not has been added to SDK1.0_r2 or Cupcake branch? Thanks for any help or solutions! :-) Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] How could I know a Service is already started?
To dear all Android developers, Is there a way to check whether a service is already started or not? This issue has been discussed ealier (and much earlier) in April, in the last year, on this forum. http://groups.google.com/group/android-developers/browse_thread/thread/2b3a7b1c5801dc9c/40b16552390f98e8?lnk=gstq=service#40b16552390f98e8 However, I wonder that does there have a new solution to this issue rather than using a SharedPreferences to store the service status. Is this functionality to check service is started or not has been added to SDK1.0_r2 or Cupcake branch? Thanks for any help or solutions! :-) Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Where could I get an ADT 0.9.0?
to dear Kenny, I have solved this problem by taking a build sequence to the ADT source code under the newly released cupcake device code, and thanks for your concern ;-) The new ADT (version 0.9.0) is under the /device- code-root/devlopment/tools/eclipse/plugins/ com.android.ide.eclipse.adt , and build the plugin with running the script file build_server.sh under the /device-code-root/devlopment/ tools/eclipse/scripts. P.s. you will need to download an eclipse with PDE functionality, and set $ECLIPSE_HOME to the eclipse root to complete this and thanks for your help again! :-) Best regards, Nicholas On 12月28日, 上午1時41分, Kenny Yu yxw...@gmail.com wrote: I built cupcake, which has been merged to master HEAD. The ADT is quite OK. Can you share more info? Kenny On Dec 26, 11:35 am, yukinoba ckmagic...@gmail.com wrote: To dear all, Does anyone have the cupcake? The SDK in there is not applicable to the ADT plugin (Android Development Tools plugin) of Eclipse any more, and Eclipse throws a message told me I should get an updated ADT with version 0.9.0. However, I tried to build one in the source, and found that the latest version in the cupcake source code is 0.8.1 rather than 0.9.0. So, is there anyone enjoyed their cupcakes with Eclipse? I need a ADT 0.9.0 support... Thx for ur help Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Emulator is not able to connect to network
to dear David, You're right. It's actually a proxy problem at all. In the cupcake version, you need to set proxy through the following steps: 1) adb shell 2) cd /data/data/com.android.providers.settings/databases 3) sqlite3 settings.db 4) INSERT INTO secure VALUES(99,'http_proxy','proxy_server:port'); I have no idea why the proxy settings under the Menu-Setting is not work at all. Thanks for your help ;-) Best regards, Nicholas On 12月19日, 下午5時41分, David Turner di...@android.com wrote: first, anyone using a proxy to connect to the Internet should really update to 1.0r2, because it contains much better http-proxy support compared to previous versions. two things that might help find more information about the problem: - does https work in the browser, if https works, but not http, it's most certainly a proxy-related problem. If https doesn't work, well, I don't know - use -debug-http-proxy when launching the emulator, and post the output here. that should probably give more information I can decode On Fri, Dec 19, 2008 at 8:49 AM, yukinoba ckmagic...@gmail.com wrote: hi David, I have the same situation to this. However, I could connect to internet by using HttpClient and get responses. The 3G icon appears in the top of Android home, but browser does not work at all. I have my own proxy address with proxy.local:80, and sets in the Eclipse preference and using -http-proxy in the emulator arguments. However, it seems these helps nothing to this. Is there any solution to this weird network problem? :-) Thx for ur help Best regards, Nicholas On 12月19日, 下午3時20分, David Turner di...@android.com wrote: first, use emulator -wipe-data to rest your /data partition.If this still doesn't solve the problem, try updating to 1.0_r2 and let us know On Fri, Dec 19, 2008 at 3:06 AM, Esther esther...@gmail.com wrote: My emulator can't connect to network by Browser or Email application but the PC does connect to internet properly with no proxy. The 3G icon on the emulator status bar never appears like the emulator running on other PC. Could someone help me on this issue? (I'm using the emulator in android-sdk-windows-1.0_r1) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Where could I get an ADT 0.9.0?
To dear all, Does anyone have the cupcake? The SDK in there is not applicable to the ADT plugin (Android Development Tools plugin) of Eclipse any more, and Eclipse throws a message told me I should get an updated ADT with version 0.9.0. However, I tried to build one in the source, and found that the latest version in the cupcake source code is 0.8.1 rather than 0.9.0. So, is there anyone enjoyed their cupcakes with Eclipse? I need a ADT 0.9.0 support... Thx for ur help Best regards, Nicholas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: HTC G2's home effection is very well,I saw it on www,Is it real or just a flash?
I m not going to offense ur dream... However, these pictures are provided and designed by Android fans only. The actual T-Mobile G2 pictures are not going to be published yet. All we know til now is G2 will have a virtual keyboard and be published during March in the next year. On 12月22日, 上午3時07分, ipalik p.christo...@googlemail.com wrote: well, google, please tell me if there is an developer edition of the g2. I have to use it in germany then. at the moment, i use the dev phone 1. but does any body know something more about the g2? thanks On 20 Dez., 10:50, Al Sutton a...@funkyandroid.com wrote: Please seehttp://groups.google.com/group/android-discuss/browse_thread/thread/e... Al. JBQ wrote: Does anybody know it? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: certificate ssl webservice keystore
I see :-) It sounds good for this security mechanism. However, I still don't know how to make an application-specific keystore for certain application only... And it sounds that Android has already provided a way for applications to safely create their own certification rather than system certification like u mentioned? Is there a guideline for this? I need this for a HTTPS connection to a weather channel site and retrieve weather information back. Thanks for ur help Best regards, Nicholas On 12月19日, 下午4時01分, Al Sutton a...@funkyandroid.com wrote: There is a very good reason why applications shouldn't be able to add certificates to the system keystore, and that's security. If an application wants a user to trust a certificate for the actions the application it's performing then that is decision made by the user in the context of that application. The application should not add that certificate to the system keystore because that would mean the the certificate becomes trusted in all applications, which is not what the user agreed to. Drawing a parallel with the desktop world; If I trust an SSL cert in FireFox that does not (and should not) make it a trusted certificate in Thunderbird. As a developer and a user I see it as a good thing that Android doesn't let applications do this, and I would be against any change to this policy just to make developers lives a bit easier. Al. yukinoba wrote: hi, I have surveyed lots of solutions to this problem. However, most solutions break (or say, cheat) the SSL verification for development usage, and surely I don't want to make this kind of solutions in my own application. Could you help to provide a guideline how to create application-specific keystore? I have been read KeyStore class in the Android SDK document but still has no idea how to make it. Thanks for ur help Best regards, Nicholas On 12月12日, 上午1時00分, Michael michael573...@gmail.com wrote: Yep, join the club. Lots of us are complaining about the inability to add certificates to the system keystore. One way that people have been working around this (in apps like k9mail, for example), is to use an application-specific keystore. -- == Funky Android Limited is registered in England Wales with the company number 6741909. The registered head office is Kemp House, 152-160 City Road, London, EC1V 2NX, UK. The views expressed in this email are those of the author and not necessarily those of Funky Android Limited, it's associates, or it's subsidiaries. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Does LogCat support UTF-8 to display?
Thx Ralf ;-) On 12月16日, 上午5時35分, Ralf ralfo...@gmail.com wrote: On Thu, Dec 11, 2008 at 11:55 PM, yukinoba ckmagic...@gmail.com wrote: hi all does anyone know thatlogcatsupports utf-8 display or not? I ve tried to transfer non-unicode string message objects to the Log method, with new String(s.getBytes(original-coding), utf-8), and then put it into the Log.v(TAG, my_transferred_string) then I found,logcatshows results with wrong encoding characters... Apparently it does not. Feel free to file a bug athttp://b.android.com R/ does anyone have an idea? best --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: certificate ssl webservice keystore
hi, I have surveyed lots of solutions to this problem. However, most solutions break (or say, cheat) the SSL verification for development usage, and surely I don't want to make this kind of solutions in my own application. Could you help to provide a guideline how to create application-specific keystore? I have been read KeyStore class in the Android SDK document but still has no idea how to make it. Thanks for ur help Best regards, Nicholas On 12月12日, 上午1時00分, Michael michael573...@gmail.com wrote: Yep, join the club. Lots of us are complaining about the inability to add certificates to the system keystore. One way that people have been working around this (in apps like k9mail, for example), is to use an application-specific keystore. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Emulator is not able to connect to network
hi David, I have the same situation to this. However, I could connect to internet by using HttpClient and get responses. The 3G icon appears in the top of Android home, but browser does not work at all. I have my own proxy address with proxy.local:80, and sets in the Eclipse preference and using -http-proxy in the emulator arguments. However, it seems these helps nothing to this. Is there any solution to this weird network problem? :-) Thx for ur help Best regards, Nicholas On 12月19日, 下午3時20分, David Turner di...@android.com wrote: first, use emulator -wipe-data to rest your /data partition.If this still doesn't solve the problem, try updating to 1.0_r2 and let us know On Fri, Dec 19, 2008 at 3:06 AM, Esther esther...@gmail.com wrote: My emulator can't connect to network by Browser or Email application but the PC does connect to internet properly with no proxy. The 3G icon on the emulator status bar never appears like the emulator running on other PC. Could someone help me on this issue? (I'm using the emulator in android-sdk-windows-1.0_r1) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Does LogCat support UTF-8 to display?
Ummm...does ANYONE know? or could Mr./Mrs. Googles answer? @_...@? Best Regards, Nicholas On 12月12日, 下午3時55分, yukinoba ckmagic...@gmail.com wrote: hi all does anyone know that logcat supports utf-8 display or not? I ve tried to transfer non-unicode string message objects to the Log method, with new String(s.getBytes(original-coding), utf-8), and then put it into the Log.v(TAG, my_transferred_string) then I found, logcat shows results with wrong encoding characters... does anyone have an idea? best --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Does LogCat support UTF-8 to display?
hi all does anyone know that logcat supports utf-8 display or not? I ve tried to transfer non-unicode string message objects to the Log method, with new String(s.getBytes(original-coding), utf-8), and then put it into the Log.v(TAG, my_transferred_string) then I found, logcat shows results with wrong encoding characters... does anyone have an idea? best --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] [Problem] Could not fine HelloAndroid.apk when lauching the HelloAndroid example
Hi, I'm a totally newbie to the Android SDK. I have been installed Eclipse 3.4 (Ganymede), ADT 0.7.1 and Android 0.9 SDK with JRE 6 updated 7. It seems weird when I follow the Hello, Android! guideline on Google site. First I encountered the problem of Android libray. It seems eclipse won't include the .jar library file under the Android directory automatically after create the HelloAndroid project, and I have fixed this one. However, after the ealier problem, when I try to run the example, the eclipse told me Could not find HelloAndroid.apk!, and stops. Here is the message: [2008-08-27 10:01:43 - HelloAndroid] -- [2008-08-27 10:01:43 - HelloAndroid] Android Launch! [2008-08-27 10:01:43 - HelloAndroid] adb is running normally. [2008-08-27 10:01:43 - HelloAndroid] Could not find HelloAndroid.apk! I have checked the posts on the forum, and try the possible solutions : check Installed JREs in Window--Preferences--Java, and the AndroidManifest.xml. But still can not fix it. Does anyone met the same situation before? Pls help and Thx. The following is the AndroidManifest.xml from HelloAndroid : ?xml version=1.0 encoding=utf-8? manifest xmlns:android=http://schemas.android.com/apk/res/android; package=com.android.hello application android:icon=@drawable/icon android:label=@string/ app_name activity android:name=.HelloAndroid android:label=@string/ app_name intent-filter action android:name=android.intent.action.MAIN / category android:name=android.intent.category.LAUNCHER / /intent-filter /activity /application /manifest --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] Announcing the new Android 0.9 SDK beta! http://android-developers.blogspot.com/2008/08/announcing-beta-release-of-android-sdk.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---