[android-beginners] Re: Plug for "Beginning Android 2"
I agree with you Doug on all points. There is however another benefit. The Warescription model. Since I started with Android about 12mths ago we have gone from version 1.5 to 1.6, 2.0, 2.1 and now 2.2. Books go out of date very quickly with Android. Geoff -- You received this message because you are subscribed to the Google Groups "Android Beginners" group. ATTENTION: Android-Beginners will be permanently disabled on August 9 2010. For more information about this change, please read [http://goo.gl/xkfl] or visit the Group home page. Try asking and tagging your question on Stack Overflow at http://stackoverflow.com/questions/tagged/android To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en
[android-beginners] Re: My column '_id' does not exist?
Mitch, you must be querying somewhere to get your cursor. When doing the query, you must ensure that it includes the "_id" column from the db. SimpleCursorAdapter will use this to differentiate rows. Geoff -- You received this message because you are subscribed to the Google Groups "Android Beginners" group. NEW! Try asking and tagging your question on Stack Overflow at http://stackoverflow.com/questions/tagged/android To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en
[android-beginners] Re: Database handling - when do you open and close
Bender, put your db in a local Service. Open the db in onCreate() close it in onDestroy(). Your Activities can bind and unbind to the Service as many times as you like. The system will keep the service running as long as you have an activity in the foreground process bound to it or otherwise until it needs to reclaim the resources. Take a look at : http://developer.android.com/resources/samples/ApiDemos/src/com/example/android/apis/app/LocalService.html but DONT have your binder as a non-static inner class as in the example - or you will create a memory leak and leak your Service. Instead, pass the binder a reference to your service in onCreate and get the binder to null the reference out in onDestroy -- You received this message because you are subscribed to the Google Groups "Android Beginners" group. NEW! Try asking and tagging your question on Stack Overflow at http://stackoverflow.com/questions/tagged/android To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en
[android-beginners] Re: Importing a class from another project in Eclipse. Application fails to run with ClassNotFoundException
> E/AndroidRuntime( 2976): java.lang.RuntimeException: Unable to > instantiate activity ComponentInfo{com.example.helloandroid/ > com.example.helloandroid.HelloAndroid}: > java.lang.ClassNotFoundException: > com.example.helloandroid.HelloAndroid in loader > dalvik.system.pathclassloa...@44948c38 > E/AndroidRuntime( 2976): Caused by: java.lang.ClassNotFoundException: > com.example.helloandroid.HelloAndroid in loader > dalvik.system.pathclassloa...@44948c38 If you haven't had this run before...Did you remember to put HelloAndroid in your manifest? -- You received this message because you are subscribed to the Google Groups "Android Beginners" group. NEW! Try asking and tagging your question on Stack Overflow at http://stackoverflow.com/questions/tagged/android To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en
[android-beginners] Confused about application context
I have a service that is opened by an Activity for the purposes of managing a SQLite database the service is passed the application context when binding... serviceIntent = new Intent(getApplicationContext(), DatabaseService.class); bindService(serviceIntent, mConnection, Context.BIND_AUTO_CREATE); The service is unbound in onPause When trying to track down memory leaks with the Binders, I opened and closed the activity a few times and then dumped the heap into MAT in Eclipse. Amongst all the other rubbish I get details as below. Is this telling me that I actually have 4 different Application Context instances at four different addresses??? Or am I just getting different pointers to the one Application Context -they all come from the same call for getApplicationContext(). I didn't think an app would have more than one Application Context,IF this is what this means. Is this something I should not be worried about? This is from a single run of my app on fresh run of the emulator. Class Name | Shallow Heap | Retained Heap --- com.ozdroid.database.DatabaseService @ 0x43c9cc60 | 56 | 1,608 |- mOuterContext android.app.ApplicationContext @ 0x43c9cc98 |120 | 152 |- this$0 com.ozdroid.database.DatabaseService$LocalBinder @ 0x43c9da50 Native Stack| 32 | 1,640 '- Total: 2 entries com.ozdroid.database.DatabaseService @ 0x43c685e8 |56 | 1,088 | - mOuterContext android.app.ApplicationContext @ 0x43c68620|120 | 152 |- this$0 com.ozdroid.database.DatabaseService$LocalBinder @ 0x43c68c78 Native Stack| 32 | 1,120 '- Total: 2 entries com.ozdroid.database.DatabaseService @ 0x43c4c760 | 56 |432 |- this$0 com.ozdroid.database.DatabaseService$LocalBinder @ 0x43c3d6a0 Native Stack| 32 | 32 |- mOuterContext android.app.ApplicationContext @ 0x43c4c798| 120 |152 |- mDbS com.ozdroid.load.LoadView @ 0x43cafea0 | 288 | 5,216 '- Total: 3 entries com.ozdroid.database.DatabaseService @ 0x43c42840 | 56 | 1,088 |- mOuterContext android.app.ApplicationContext @ 0x43c42878| 120 | 152 |- this$0 com.ozdroid.database.DatabaseService$LocalBinder @ 0x43c44a60 Native Stack| 32 | 1,120 '- Total: 2 entries | | Total: 4 entries | | --- -- You received this message because you are subscribed to the Google Groups "Android Beginners" group. NEW! Try asking and tagging your question on Stack Overflow at http://stackoverflow.com/questions/tagged/android To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en
[android-beginners] Re: easy way to embed a button in a mapview?
Thanks Mark. -- You received this message because you are subscribed to the Google Groups "Android Beginners" group. NEW! Try asking and tagging your question on Stack Overflow at http://stackoverflow.com/questions/tagged/android To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en
[android-beginners] Re: easy way to embed a button in a mapview?
Just an outside chance, if you have any trouble... I have no experience with MapView. This may be really dumb, but.. You may be able to put the MapView in a RelativeLayout , layout the MapView first in the Relative Layout and have it FillParent for height and width. Then put the Button next in your xml, in the same relative layout, to draw your button on top. Your layout options may be a bit limited but you might be able to align it to an edge or centre it somewhere and pad it a bit to get it away from the edge. I'd imagine you would want to be careful not to obscure the Google logo and zoom controls.. On Mar 12, 4:12 am, Michael Dorin wrote: > Is there an easy way to embed a button inside a map view? > I have been able to create a button above and below and alongside a mapview, > but I can't seem to plunk it inside. > > I would like the mapview to use the whole screen. > > Thank you, > Mike -- You received this message because you are subscribed to the Google Groups "Android Beginners" group. NEW! Try asking and tagging your question on Stack Overflow at http://stackoverflow.com/questions/tagged/android To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en
[android-beginners] Re: Parcel.createStringArray() throwing errors
> For now you could loop through the items and add them as strings. If > your array will change in length, add an int first to tell the reciver > how many array strings to loop through. Good idea > I know it isn't ideal... True ... but then it's functional. > Are you accessing the parcel from an aidl file? No I'm not but I am usining the class I'm passing through in a lot of places and it carries data that will end up in a SQLite database - I just want to enforce a little type safety on my code... rather than just pass through a heap of ints and Strings and hope I dont make errors. Thanks for the idea:) -- You received this message because you are subscribed to the Google Groups "Android Beginners" group. NEW! Try asking and tagging your question on Stack Overflow at http://stackoverflow.com/questions/tagged/android To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en
[android-beginners] Parcel.createStringArray() throwing errors
This doesn't seem to be working properly. What I am trying to do is pass a class through onActivityResult() using a Bundle I have put in the associated Intent. To this end, I have made my class implement Parcelable with all the associated methods and CREATOR. The parcel is written when, eventually, the following method is called public void writeToParcel(Parcel dest, int flags) { Log.d(TAG,"writing to parcel..."); dest.writeInt(value); dest.writeStringArray(options); dest.writeIntArray(conversions); dest.writeInt(system); } ...and read back out later with private void readFromParcel(Parcel in) { Log.d(TAG,"reading from parcel..."); in.setDataPosition(0); value = in.readInt(); options = in.createStringArray(); conversions = in.createIntArray(); system = (short) in.readInt(); } My problem is that when creating the "options" String Array, I get the error below. When I remove the lines that write and create the String array everything works fine. As you can see, I'm being told that an array size is too large. The array has THREE elements. Has anyone had experience with this? Is there something I'm overlooking? 02-18 17:30:50.880: ERROR/AndroidRuntime(10814): Uncaught handler: thread main exiting due to uncaught exception 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): java.lang.InternalError: array size too large HERE<< 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.os.Parcel.createStringArray(Parcel.java:813) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at com.ozdroid.model.measurement.Mass.readFromParcel(Mass.java:202) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at com.ozdroid.model.measurement.Mass.(Mass.java:89) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at com.ozdroid.model.measurement.Mass.(Mass.java:88) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at com.ozdroid.model.measurement.Mass$1.createFromParcel(Mass.java:29) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at com.ozdroid.model.measurement.Mass$1.createFromParcel(Mass.java:1) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.os.Parcel.readParcelable(Parcel.java:1903) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.os.Parcel.readValue(Parcel.java:1771) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.os.Parcel.readMapInternal(Parcel.java:2005) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.os.Parcel.readBundleUnpacked(Parcel.java:1405) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.os.Bundle.unparcel(Bundle.java:159) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.os.Bundle.getString(Bundle.java:966) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at com.ozdroid.load.LoadView.onActivityResult(LoadView.java:294) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.app.Activity.dispatchActivityResult(Activity.java:3614) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.app.ActivityThread.deliverResults(ActivityThread.java:3001) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.app.ActivityThread.handleSendResult(ActivityThread.java:3047) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.app.ActivityThread.access$2300(ActivityThread.java:112) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1721) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.os.Handler.dispatchMessage(Handler.java:99) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.os.Looper.loop(Looper.java:123) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at android.app.ActivityThread.main(ActivityThread.java:3948) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at java.lang.reflect.Method.invokeNative(Native Method) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at java.lang.reflect.Method.invoke(Method.java:521) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at com.android.internal.os.ZygoteInit $MethodAndArgsCaller.run(ZygoteInit.java:782) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:540) 02-18 17:30:50.900: ERROR/AndroidRuntime(10814): at dalvik.system.NativeStart.main(Native Method) -- You received this message because you are subscribed to the Google Groups "Android Beginners" group. NEW! Try asking and tagging your question on Stack Overflow at http://stackoverflow.com/questions/tagged/android To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en
[android-beginners] HTC Hero does not support imeOptions ="actionDone"
Just discovered that with my Hero if you use android:imeOptions="actionDone" in your XML for an EditText that when the app is run on a HTC Hero, the Enter key does not change to "Done" as it does on emulator and my onEditorActionListener will not capture EditorInfo.IME_ACTION_DONE as it will on the emulator. Need to capture the enter key as well. -- You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en
[android-beginners] Re: How to Align button to button of screen???
Matt, The second text view cannot have height = fill parent On Oct 27, 6:23 am, Matt Raffel wrote: > I tried that :) I created a second textview control. It ends up > pushing the button off the bottom of the screen. > > android:layout_width="fill_parent" > android:layout_height="wrap_content" > android:text="@string/hello" > /> > android:layout_width="fill_parent" > android:layout_height="fill_parent" <<< -- this will fill screen > and leave no room for Button > android:text="@string/empty_string" > /> > android:layout_width="fill_parent" > android:layout_height="wrap_content" > android:gravity="bottom" > android:text="@string/btn_start_game" > /> Use a Relative Layout instead as recommended by paul. Something like this may work ( I haven't checked - but you get the idea) http://schemas.android.com/apk/res/ android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:background="@drawable/blankscreen" > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] Re: Android Books
I found Mark Murphy's warescription at http://commonsware.com to be very useful. You get three books in pdf ( or kindle i think) that are updated regularly - which is useful as Android is still evolving. Lots of code samples. Mark is a regular contributor in these forums and will answer all of your questions on his own group providing that you keep to the groups topic ie. content in the books. Geoff On Oct 26, 1:34 am, NIK wrote: > Hi all i am new to android programing. I have already been programing > in J2ME and i wanted to know any opinions about android books that > could help me get in touch with it. I don't want a beginners books > because i can use the resources in the android site. Any suggestions > are appreciated. > Thanks in advance. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] Re: How to control the behaviour of the virtual keyboard "next" key?
I think you can use android:nextFocusDown="@+id/" in your XML layout file to shift focus to the next view. When you are on the last one the "Next" key goes to "done" geoff On Oct 25, 8:24 am, ohnoezitasploded wrote: > Hi All, > I'm writing an app that includes a dialog where the user must > enter some information in editTexts. > > The dialog has four editTexts in a row, and another editText below > that (IP address and port). So we have: > > [e1] [e2] [e3] [e4] > [e5] > > If the cursor is in editTexts 1-4, the virtual keyboard displays a > "next" button, which is great and very handy. However, it only seems > to search down, i.e. if you are in [e2] it will move the cursor to > [e5], not [e3] as expected. > > Is there a way to control which box it goes to next? It seems like > there should be an xml property for ordering, but I haven't found > anything like that. > > Thanks! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] Re: Trouble with a cursor
Thanks Guys for your help. I found the problem. - It was the query. The "limit" parameter for the number of rows returned is a String - as to why it is a String rather than an int is anyones guess. However, where I made my error was by having a leading and trailing space ie " 1 " instead of "1". Your efforts were appreciated. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] Re: Trouble with a cursor
Thanks, but I tried that earlier. moveToFirst() also calls count() and results in same error ... sigh On Oct 22, 5:08 pm, zhen guo wrote: > before getCount, you should add cursor.moveToFirst(). > > On Thu, Oct 22, 2009 at 1:05 PM, brucko wrote: > > > I'm having trouble with a SQLite database that I have on the SDCard. > > > when I do a query that returns a cursor I keep getting an error when i > > try to call the count() method. > > > Here's the code > > > Cursor cursor = mDb.query > > (LOGON_TABLE, // table > > new String[] { KEY_ROW_ID }, > > // > > columns, > > KEY_USER_NAME + " = ? AND " + > > KEY_CARRIER_ID + " = ? AND " > > + > > KEY_DEPOT + " = ? AND " + > > KEY_TIME + " = ? AND " + > > KEY_RUN + " = ?", > > //selection, > > new String[] { user, carrier, depot, > > logonTime, run },// > > selectionArgs, > > null, null, null, > > // > > groupBy, having, orderBy > > " 1 > > "); // > > limit > > > if (cursor.getCount() < 1) { <--error occurs here > > ... > > } > > > It gives a datatype mismatch as a result of calling count... > > > 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): > > android.database.sqlite.SQLiteException: datatype mismatch > > > 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at > > android.database.sqlite.SQLiteQuery.native_fill_window(Native Method) > > 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at > > android.database.sqlite.SQLiteQuery.fillWindow(SQLiteQuery.java:75) > > 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at > > android.database.sqlite.SQLiteCursor.fillWindow(SQLiteCursor.java:288) > > 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at > > android.database.sqlite.SQLiteCursor.getCount(SQLiteCursor.java:269) > > 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at > > android.database.AbstractCursor.moveToPosition(AbstractCursor.java: > > 171) > > 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at > > android.database.AbstractCursor.moveToFirst(AbstractCursor.java:248) > > 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at > > com.paperfree.database.DatabaseService.insertLogon > > (DatabaseService.java:288) > > 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at > > com.paperfree.load.LoadView$2.onServiceConnected(LoadView.java:76) > > 10-22 04:53:20.471: ERROR/AndroidRuntime(22252): > > android.database.sqlite.SQLiteException: datatype mismatch > > 10-22 04:53:20.471: ERROR/AndroidRuntime(22252): at > > android.database.sqlite.SQLiteQuery.native_fill_window(Native Method) > > 10-22 04:53:20.471: ERROR/AndroidRuntime(22252): at > > android.database.sqlite.SQLiteQuery.fillWindow(SQLiteQuery.java:75) > > 10-22 04:53:20.471: ERROR/AndroidRuntime(22252): at > > android.database.sqlite.SQLiteCursor.fillWindow(SQLiteCursor.java:288) > > > 10-22 04:53:20.471: ERROR/AndroidRuntime(22252): at > > android.database.sqlite.SQLiteCursor.getCount(SQLiteCursor.java:269) > > > 10-22 04:53:20.471: ERROR/AndroidRuntime(22252): at > > com.paperfree.database.DatabaseService.insertLogon > > (DatabaseService.java:268) > > > The database file is on the sdCard and all the columns are there, but > > I haven't put any data there so I am expexcting a cursor with zero > > rows. > > > Thanks --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] Trouble with a cursor
I'm having trouble with a SQLite database that I have on the SDCard. when I do a query that returns a cursor I keep getting an error when i try to call the count() method. Here's the code Cursor cursor = mDb.query (LOGON_TABLE,// table new String[] { KEY_ROW_ID }, // columns, KEY_USER_NAME + " = ? AND " + KEY_CARRIER_ID + " = ? AND " + KEY_DEPOT + " = ? AND " + KEY_TIME + " = ? AND " + KEY_RUN + " = ?", //selection, new String[] { user, carrier, depot, logonTime, run },// selectionArgs, null, null, null, // groupBy, having, orderBy " 1 ");// limit if (cursor.getCount() < 1) {<--error occurs here ... } It gives a datatype mismatch as a result of calling count... 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): android.database.sqlite.SQLiteException: datatype mismatch 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at android.database.sqlite.SQLiteQuery.native_fill_window(Native Method) 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at android.database.sqlite.SQLiteQuery.fillWindow(SQLiteQuery.java:75) 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at android.database.sqlite.SQLiteCursor.fillWindow(SQLiteCursor.java:288) 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at android.database.sqlite.SQLiteCursor.getCount(SQLiteCursor.java:269) 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at android.database.AbstractCursor.moveToPosition(AbstractCursor.java: 171) 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at android.database.AbstractCursor.moveToFirst(AbstractCursor.java:248) 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at com.paperfree.database.DatabaseService.insertLogon (DatabaseService.java:288) 10-22 04:20:21.330: ERROR/AndroidRuntime(15768): at com.paperfree.load.LoadView$2.onServiceConnected(LoadView.java:76) 10-22 04:53:20.471: ERROR/AndroidRuntime(22252): android.database.sqlite.SQLiteException: datatype mismatch 10-22 04:53:20.471: ERROR/AndroidRuntime(22252): at android.database.sqlite.SQLiteQuery.native_fill_window(Native Method) 10-22 04:53:20.471: ERROR/AndroidRuntime(22252): at android.database.sqlite.SQLiteQuery.fillWindow(SQLiteQuery.java:75) 10-22 04:53:20.471: ERROR/AndroidRuntime(22252): at android.database.sqlite.SQLiteCursor.fillWindow(SQLiteCursor.java:288) 10-22 04:53:20.471: ERROR/AndroidRuntime(22252): at android.database.sqlite.SQLiteCursor.getCount(SQLiteCursor.java:269) 10-22 04:53:20.471: ERROR/AndroidRuntime(22252): at com.paperfree.database.DatabaseService.insertLogon (DatabaseService.java:268) The database file is on the sdCard and all the columns are there, but I haven't put any data there so I am expexcting a cursor with zero rows. Thanks --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] Re: Development Phone
I'll be the first to admit that I am a bit of a novice in the android arena. What I would like to bring to your attention is that there may well be very good reasons as to why some pre-installed apps can be hard to change. I'm trying to import some devices into Australia, many of our regulations are based on the US and Europe. If you change some of the key software on a phone you may very well make it illegal to use that phone. One key example would be the requirement we have to be able to dial emergency numbers even when the screen is locked. Someones life may depend on this functionality being intact. I have no idea what the legal ramifications would be of making software available that did not maintain this ability. However selling, giving or even loaning phones with emergency dialing no longer enabled would certainly be an offense. ( Not saying you shouldn't replace these apps - just be careful) ...brucko On Aug 29, 3:53 am, Chris Stratton wrote: > On Aug 24, 9:09 am, Ran wrote: > > > What is the benefit of working with ADP1 over the other Android > > phones ? > > Just to expand on what others have said: > > Cost seems comparable betwen a dev phone and a retail phone at full > retail or plan price + termination fee, so it's really more a of a > technical question. > > Reasons for a dev phone > > -sim unlocked (some such as tmobile may? do that if you pay full > retail or eventually on a plan) > -can change linux and system libraries > -can change pre-installed applications > -tmobile myfaves application sends periodic sms which costs money on > any other network > > Reasons for _not_ getting a dev phone > > -only one older dev phone model generally available at present > -dev phones can't buy paid applications from the market (including > your own) > -if you sell apps, you need to restrict yourself to the capabilities > of your users phones (and test on such a device!) > -various preinstalled proprietary applications missing (+/- depending > on your interest) > > The not being able to change preinstalled applications is in my mind > the least anticipated, and most annoying, problem. There are many > areas where very small decisions of questionable wisdom in default > applications really hamper the user experience (even in the using it > just to make calls sense), but these can't be very readily changed on > a retail phone, particularly the parts most closely involved in the > telephone functionality. > > As of this moment, I believe most of the retail phones are probably > still shipping with an easily rooted linux kernel, but that probably > will get closed up (already fixed in google's tree) and they will be > limited until another hole is found. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---
[android-beginners] Re: Defaulting to numeric keyboard on EditText without forcing numeric input.
Mike, I only just saw this - sorry late reply. You've probably solved by now. Give XML attribute for your edit text android:inputType="number" Best Regards, Geoff On Aug 6, 11:26 pm, Mike Olson wrote: > I have an EditText that I don't want to force to be a number, but > chances are it almost always will start with a number (The field is > "Quantity", and I'd like to to be freetext, so I can write "1 oz", "2 > boxes", etc). > > Is there a way to have the on-screen keyboard default to the numeric > keyboard, but still allow me to enter letters if I press the "ABC" > button? If I say add android:number="integer" it won't allow non- > numeric inputs. > > Thanks, > Mike --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~--~~~~--~~--~--~---