Wrox Programmer Forums
BOOK: Professional Android 4 Application Development
This is the forum to discuss the Wrox book Professional Android 4 Application Development Reto Meier; ISBN: 978-1-1181-0227-5
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional Android 4 Application Development section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old January 24th, 2013, 09:03 AM
Authorized User
Join Date: Jan 2013
Posts: 27
Thanks: 1
Thanked 0 Times in 0 Posts
Default Problems to add support library in Eclipse

Hello Reto,

From your (very well informing and thorough!) book on p. 27, "incorporate a support library", i understood that when i inserted android-support-v4.jar in my build path, then i could support platforms with api 4 or above for classes that were introduced in api 11 for instance.
I installed via Android tools/support library after rigtht clicking the project in the package view and updated the java build path many times, but nothing helps to escape from the warnings that i use classes for API 11 and that the minimum SDK is lower.. So the only thing that helps is change the minimum in the manifest to 11.
It is only clear that for instance a class from api 11 like Notification.Builder, see chapter 10, is not covered by this support library.

Last edited by Kees; January 24th, 2013 at 03:46 PM.. Reason: The problem source is not as mentioned
Old January 24th, 2013, 12:07 PM
Authorized User
Join Date: Jan 2013
Posts: 27
Thanks: 1
Thanked 0 Times in 0 Posts
Smile Problem to add support library in Eclipse "solved"

After some more reading in the developers guide i found that the problem was not a bug in Eclipse but my expectation that i could just use an api 11 class like Notification.Builder with android-support-v4 to support an older platform than api 11. See page 410 in the book for instance.
So Notification.Builder is not present in the support lib, but when it is renamed to NotificationCompat.Builder, then it is recognised also with lower minimum SDK than 11
It is now apparent to me that just adding the support library to the java build path is not enough to use the same code for lower platforms. The code has also to be adapted for the classes that are involved...

Last edited by Kees; January 24th, 2013 at 04:01 PM..

Similar Threads
Thread Thread Starter Forum Replies Last Post
problem with add web user control to Class library project hamed88 BOOK: Professional DotNetNuke Module Programming ISBN: 978-0-470-17116-5 0 May 5th, 2011 03:32 AM
Chapter 42 - How do I add a Component Library Project? Lammatron2000 BOOK: Professional C# 2008 ISBN: 978-0-470-19137-8 1 July 12th, 2010 09:09 AM
Adding to a class library using the List..Add BigJay86 C# 2 June 23rd, 2006 04:08 PM
Plugin problem of Eclipse with Struts inderjeet_79 BOOK: Professional Jakarta Struts 0 September 22nd, 2005 05:03 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.