On Jan 23, 2:20 pm, Mark Murphy <[email protected]> wrote: > On Mon, Jan 23, 2012 at 5:09 PM, Bret Foreman <[email protected]> wrote: > > But if I build with API 10 on run on Android 2.2.2 then my > > MainActivity throws a ClassNotFoundException. > > > Something in the Activity constructor for API 10 is barfing in Android > > 2.2.2, which I guess is no real surprise. > > It's surprising to me. What class is not being found? >
The MainActivity class is not being found. In other words, it can't instantiate an Activity. This is my first time trying to build at one level and run at another. Is it supposed to work? > > Is there a good way to fix this short of modifying the other guy's > > code to remove the call to createInsecureRfcommSocketToServiceRecord > > and always call createRfcommSocketToServiceRecord? > > Compile it to a JAR using API Level 10. Reference the JAR from your > API Level 8 project. I'm a bit dubious about NoSuchMethodError (I > would expect a VerifyError), but otherwise this might work. > > The other developer really should be using Build.VERSION, just for > this sort of reason. > I'll re-code the section using Build.VERSION and see if I can get the other developer to drop that in. -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

