Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Mobile Development > BOOK: Professional Android 2 Application Development
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Professional Android 2 Application Development
This is the forum to discuss the Wrox book Professional Android 2 Application Development, 2nd Edition by Reto Meier; ISBN: 978-0-470-56552-0
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional Android 2 Application Development section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old March 20th, 2010, 12:04 PM
Registered User
 
Join Date: Mar 2010
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Exclamation Chapter# 2 - Page 23 what to key in the new Android Project

I don't know why, but the auther didn't give what we should key in the New Android Project (Chapter 2 page 23), it just say fill these fields.

I put in the Project name, Application Name, but I don't know what to put on the followings:

Package Name:
Create Activity:
Min SDK Version: <== maybe the least android vertion that we want our apps to support?


Any help will be appreciated, I tried to key anything, but it's not valid and I can't pass this very first form.
Reply With Quote
  #2 (permalink)  
Old March 20th, 2010, 12:17 PM
Reto's Avatar
Wrox Author
Points: 287, Level: 5
Points: 287, Level: 5 Points: 287, Level: 5 Points: 287, Level: 5
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2008
Location: London, United Kingdom
Posts: 61
Thanks: 1
Thanked 7 Times in 6 Posts
Default

Step 3 tries to explain what each of these fields requires:

Package Name: Is a Java package name to which your project will belong. The standard form for this is <domainsuffix>.<domain>.<projectname> -- for example com.paad.earthquake

Create Activity: Lets you specify the name of an Activity class to create within your project. This will have the default 'Hello World' UI to begin with. An example would be MyActivity

Min SDK Version: Lets you specify what version of the Android SDK you want to develop for. To use the latest platform version (2.1) specify 7. Android 1.5 is SDK Version 3.

Hope that helps!
__________________
Reto Meier

Author, "Professional Android 4 Application Development", Wrox, ©2012, 2010, 2008
@retomeier
Reply With Quote
  #3 (permalink)  
Old March 20th, 2010, 12:25 PM
Registered User
 
Join Date: Mar 2010
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Unbelievable!!!, that was quick, within minutes I got your answer to my question. Thank you so much

I got all what you said, except the Package Name, this is my first time developing for Java. (I developed applications for VB .Net, VBA, .ASP, XHTML with CSS,). So where in my package of Java do I find <domainsuffix>.<domain>.<projectname>?
Reply With Quote
  #4 (permalink)  
Old March 20th, 2010, 12:28 PM
Reto's Avatar
Wrox Author
Points: 287, Level: 5
Points: 287, Level: 5 Points: 287, Level: 5 Points: 287, Level: 5
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2008
Location: London, United Kingdom
Posts: 61
Thanks: 1
Thanked 7 Times in 6 Posts
Default

You get to make it up! Java packages need to be unique (and Java's heritage is the Internet) so generally people would create package names based on their websites (they don't have to be though -- anything likely to be unique is fine).

For examples in the book I use com.paad.projectname -- for instance com.paad.earthquake or com.paad.todolist. Google uses com.google.android.apps.projectname. You can use whatever you want!

Most people like to use com.<mycompany>.<projectname> - that's what I recommend you do.
__________________
Reto Meier

Author, "Professional Android 4 Application Development", Wrox, ©2012, 2010, 2008
@retomeier
Reply With Quote
  #5 (permalink)  
Old March 20th, 2010, 03:31 PM
Registered User
 
Join Date: Mar 2010
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thank you so much man!
Reply With Quote
  #6 (permalink)  
Old August 28th, 2010, 11:26 PM
Registered User
 
Join Date: Aug 2010
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

This post got me farther along, but I followed the instructions and get the error:

project cannot be built until path errors are resolved

main.xml containing the UI part was not created either. Any help appreciated.

Thx
Reply With Quote
  #7 (permalink)  
Old August 28th, 2010, 11:34 PM
Registered User
 
Join Date: Aug 2010
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Solved path error. I'll try to get the rest working while waiting for reply.
Reply With Quote
  #8 (permalink)  
Old August 29th, 2010, 12:19 AM
Registered User
 
Join Date: Aug 2010
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Got the main.xml part worked out. But now the emulator has been trying to launch for 30 mins. It has the android graphic, not text. The console log might help. Sorry for all of this I haven't felt like a newb since before the terms was coined. I haven't used java in over 20 yrs.

Console Log:

[2010-08-28 22:50:33 - Hello World 3] ------------------------------
[2010-08-28 22:50:33 - Hello World 3] Android Launch!
[2010-08-28 22:50:33 - Hello World 3] adb is running normally.
[2010-08-28 22:50:33 - Hello World 3] Performing com.pssnow.helloworld.MyActivity activity launch
[2010-08-28 22:50:33 - Hello World 3] Automatic Target Mode: Preferred AVD 'test' is not available. Launching new emulator.
[2010-08-28 22:50:33 - Hello World 3] Launching a new emulator with Virtual Device 'test'
[2010-08-28 22:50:37 - Hello World 3] New emulator found: emulator-5554
[2010-08-28 22:50:37 - Hello World 3] Waiting for HOME ('android.process.acore') to be launched...

I have min version set to 7
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Chapter 23 - Building the Consumer phil-c- BOOK: Professional VB 2005 ISBN: 0-7645-7536-8 1 January 20th, 2009 11:52 AM
Chapter 1, Page 23 golden_drifter BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6 7 July 9th, 2004 12:12 AM



All times are GMT -4. The time now is 01:59 PM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.