[android-beginners] Re: Eclipse Project Dependencies

2009-12-30 Thread CosminB
Hi,

I'm having the same problem. Did you find a solution to this yet?

Thanks,
Cosmin

On Nov 18, 4:50 am, GT gswee...@gmail.com wrote:
 I have found several posts about people who have Project References
 working fine and people who don't.  I haven't found any solutions
 though.

 I am trying to use a class that is in a different project but I have
 not been succesful.  I have tried using Project References to get
 Android project A to reference Android project B which has the class I
 want to use.  Eclipse couldn't find the class so I assume that isn't
 enough.
 I then added Project B to Project A's build path via the Java Build
 Path control in Project A's properties.  Eclipse could then find the
 class but I get a NoClassDefFoundError exception when I run Project A
 in the emulator.

 I have also tried rearranging the build order in Order and Export.
 I even tried adding the class folder of Project B's .class file to
 Project A's Libraries.

 I feel like there is something simple right in front of me that I am
 overlooking but I haven't found it.  Does anyone have any
 recomendations for project references in Eclipse?

 Eclipse version:  Eclipse IDE for Java Developers       1.2.1.20090918-0703
 Android SDK version: Android 2.0

-- 
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: Conversion to Dalvik format failed with error 1

2009-12-30 Thread Conny
When you say build path, what do you mean ? Please specify the path.

Siddharth

On Dec 27, 10:42 am, Vant shav...@gmail.com wrote:
 Would like to push this up for more insight as well. After trying many
 things multiple times, Fix Properties, Cleans, imports, existing
 projects, nothing seemed to correct this error. Tried just about
 anything that I could find on the internet relating to this issue with
 no success. Finally I just tried deleting my android.jar file in the
 build path and that seemed to do the trick. Not sure why that is the
 case however. Hopefully this post will help someone else in the
 future.

 On Dec 10, 3:54 am, MCON Dev mcon...@gmail.com wrote:



  Hi,

  Using android on eclipse can be frustating sometimes.You create a new
  android project and just cant get it to build, run or clean out the errors
  eclipse shows up. Most of all, you can get vague errors like the below.
  Frankly its about time a bug gets logged and fixed, its adding to startup
  frustation right. Someone in google should hear this.

  Conversion to Dalvik format failed with error 1
  Could not *find* HelloAndroid.*apk*
  Updates (from 0.9.1. to 0.9.5) dont work, vague error there too some
  org.eclipse.something is not linking (google, if you are hearing, just do a
  google search out there find out the issues people are facing). Uninstalls
  dont work.

  Did a major research :), to figure out how to fix it. Found many that
  helped, found many that did not. And I am not alone there.

  So this is what I did and it worked.
  - Close all projects
  - Restart Eclipse
  - Uninstall both Android under Help-SoftwareUpdates
  - Restart Eclipse
  - Uncheck all under Help-SoftwareUpdates-AvailableSoftware, except the
  dl-sslgoogle one, install it
  - Restart Eclipse
  - Create a new project now, same problem eh!! :)
  - In the root directory of the project you just created, open the .classpath
  file. Cahnge it to the following
  *?xml version=1.0 encoding=UTF-8?
  classpath
   classpathentry kind=src path=src/
   classpathentry kind=src path=gen/
   classpathentry kind=output path=bin/
          classpathentry kind=con
  path=com.android.ide.eclipse.adt.ANDROID_FRAMEWORK/
  /classpath*
  - Main Menu - Project - Clean
  - Project Explorer - New Project you just created - Right Click -
  Properties - Android - Check Android 1.5 - Hit Apply (a lot of magic happens
  in the console tab on the project)
  - Project Explorer - New Project you just created - Right Click -
  Properties - Java Build Path - Libraries - Verify if you see a Android 1.5
  and not a android.jar.
  *The only way to add a Android 1.5 is to edit the classpath file. Google,
  you should fix this. It would be nice to know what Android 1.5 signifies
  here, a jar, external jar, variable, class folder, external class folder or
  library(usability issue, think about it, how do I add a Android 1.5 from UI,
  no way now right). Also it would be nice if the create new android project
  would fix this automatically.*

  Siddharth- Hide quoted text -

 - Show quoted text -

-- 
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] SAX, XML, and odd results

2009-12-30 Thread Lovedumplingx
So I'm trying to add a list of files to a listview by parsing their
names out of an XML file using the SAX parser.

For some reason though I'm getting a blank data element inserted
before my file name's are processed and I can't figure out why.

My XML looks like:
?xml version=1.0?
fileList
filearch enemy - dead eyes see no future.mp3/file
filetemp.jpg/file
fileBaltimora - Tarzan Boy/file
fileresearch_doc4.pdf/file
/fileList

My XML is well formed and here is the code I use to parse it:
sp.parse(new InputSource(socket.getInputStream()), new DefaultHandler
{
 public void characters(char ch[], int start, int length) throws
SAXException
 {
  super.characters(ch, start, length);
  String xmlCharacterData = new String(ch, start, length);

  files.add(xmlCharacterData.trim());
  }
});

Any thoughts?

-- 
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: Learning from Mark Murphy's book - threading question

2009-12-30 Thread alexk-il
Hi Mark,

Thanks for your help. I am registering for the CW group as well.

Cheers
Alex

P.S. My example also needs to be fixed :). The declaration
 boolean isRunning=false;
should be put before the onStart() definitions (within the class
scope).


On Dec 28, 7:29 pm, Mark Murphy mmur...@commonsware.com wrote:
 alexk-ilwrote:
  Hi,

  I'm really enjoying Mark's Beginning Android - everything is clear
  and straight to the point.

  I wonder why in the Threading example the isRunning flag wasn't
  declared volatile. The flag is used to stop a thread from another
  thread.

  In case you have the book (or even wrote it :) ) - it's on page 143.
  In case you don't, the simplified version of the code goes like this:

  public class fooBar extends Activity{
     ...
     public void onStart() {
         super.onStart();

         // why not volatile?
         boolean isRunning=false;

         Thread BG=new Thread(new Runnable() {
             public void run() {
                try {
                    while(isRunning){
                       // Do something
                    }
                }
                catch (Throwable t) {
                   // Do something
               }
        });

        isRunning=true;
        background.start();
     }

     public void onStop() {
        super.onStop();
        isRunning=false;
     }
  }

  I know, the code works on android, so what am I mising here?

 Hm...

 Usually, I use AtomicBoolean rather than volatile, but I apparently used
 neither here. On the whole, booleans are as thread-safe as a datatype
 gets, since we're only talking about a bit. That being said, I am being
 a bit sloppy there, and should improve matters.

 Thanks for pointing it out!

 BTW, you're welcome to use the [cw-android] Google Group for questions
 on _Beginning Android_:

 http://groups.google.com/group/cw-android

 --
 Mark Murphy (a Commons 
 Guy)http://commonsware.com|http://twitter.com/commonsguy

 Android Training in US: 8-12 February 2010:http://bignerdranch.com- Hide 
 quoted text -

 - Show quoted text -

-- 
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: Insert into sql Db from EditText Fields with Button?

2009-12-30 Thread MWarren
I have to say I think we are looking for the same thing.  I think I
posted to anddev and have what I tried posted on there but it seems
that unless you stir up something people wont respond or it truly is
all beginners and people only want to act smart by making remarks that
do not lead to getting help but rather wasting storage on someones
server.  Anyways I have alot pasted for what I was trying but cannot
find out whats wrong, this is a fairly difficult transition for me as
I have developed in html an php since 93 and this is so foreign to
me.  Anyways here is the link to my posting that contains copies of
the scripts I wrote but need fixed:
http://www.anddev.org/basic_settings_page_just_not_working_help_needed-t9857.html

On Dec 28, 4:23 pm, Justin Anderson janderson@gmail.com wrote:
 So what exactly are you needing help with?  The SQL statement to do the
 insert?  Creating the database itself?  Creating the UI?  Hooking the UI up
 to a button or some other event?

 --
 There are only 10 types of people in the world...
 Those who know binary and those who don't.
 --



 On Fri, Dec 25, 2009 at 5:00 PM, iloveDroid iconnel...@gmail.com wrote:
  Hello, im working on a simple Android app, it is much like any other
  simple Database app. I have 4 EditText fields where the user inputs 4
  different small pieces of text. I want this text to be inserted in to
  my Database table in the corrects rows for my columns. I am not really
  sure how to go about doing this. I know onClickListener needs to be
  used but not sure how to use it.

  The official documentation and tutorials are sort of rubbish (No
  Offense)

  --
  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.comandroid-beginners%2bunsubscr­...@googlegroups.com
  For more options, visit this group at
 http://groups.google.com/group/android-beginners?hl=en- Hide quoted text -

 - Show quoted text -

-- 
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] creating Family of apps

2009-12-30 Thread Vladimir Lebedev-Schmidthof
Hello everyone,

I'm trying to create a set of applications. Each one should have its
own package name (to have possibility to install more than one on same
device), partly different set of resources and assets. And using same
Java sources, yes.

The first thing I thought of is to preprocess the source code and xml
resources (couple of mine use custom attributes) as well as
AndroidManifest.xml to some separate directory and build the package
there.

But I really hope that there are more beautiful solution to this.

Is it?

-- 
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: r cannot be resolved and other Eclipse/Android oddities

2009-12-30 Thread XCaffeinated
Hi oregonduckman,

For the R cannot be resolved issue, make sure your R import is in
the form:

  import your.package.name.R

Sometimes a default of:

  import android.R

will appear (I've not figured out the metric that causes this to
occur). Remove the android.R import, and replace it with
your.package.name.R. Hopefully this will help.

As far as the build path errors issue, again I've not figured out
exactly what triggers this, but if you touch any of your project files
(i.e., make an inconsequential change and resave it, so Eclipse thinks
it needs to be rebuilt, or use a Touch utility), and rebuild, this
should hopefully help too. You may have to do it twice. I usually just
pick one of the project's .java files and touch that.

Hope this helps!
XCaf



On Dec 28, 3:41 pm, oregonduckman oregonduck...@gmail.com wrote:
 I frequently receive the error r cannot be resolved when adding
 functionality to an application and I have no idea why this happens.
 The change can be as simple as adding an ArrayList when the error
 appears in Eclipse.

 I have also seen the same kind of thing with the error message The
 project cannot be built until build path errors are resolved
 appearing after closing Eclipse then re-opening it with a given
 project.

 Are these just Eclipse/Android Plugin idiosyncrasies or  I am doing
 something wrong?

 My development environment is Leopard+    Eclipse Platform
 3.5.1.M20090917-0800+  Android Development Tools
 0.9.5.v200911191123-20404

-- 
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] About Sqlite Database

2009-12-30 Thread Rabby
I have done database related work by android that was succesfully work
and show the data on the listview and insert,update,delete operation
is ok now, but I have one problem, I can't get the database, only i
see the database name by using eclipes

windows--show view --others --File explorar

when i run my application in android mobile, there is no data at first
time, and database backup is not found

how can i solve this
problem...


i create the database by this
way


Constants.java
import android.provider.BaseColumns;

public interface Constants extends BaseColumns {
   public static final String TABLE_NAME = myupdate;

   // Columns in the Events database
   public static final String NAME = name;
  // public static final String  ADDRESS = address;
   //public static final String MOBILE = mobile;
   // static final String  HOME= home;
}

DBHelper.java
import static android.provider.BaseColumns._ID;
import static dbupdate.example.com.Constants.TABLE_NAME;
import static dbupdate.example.com.Constants.NAME;
//import static dbproject.example.com.Constants.ADDRESS;
//import static dbproject.example.com.Constants.MOBILE;
//import static dbproject.example.com.Constants.HOME;
import android.content.ContentValues;
import android.database.SQLException;
import android.util.Log;
import android.database.Cursor;
import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;

public class DBHelper extends SQLiteOpenHelper {
   private static final String DATABASE_NAME = UpdateDB;
   private static final int DATABASE_VERSION = 1;
   private SQLiteDatabase db;
   /** Create a helper object for the Events database */
   public DBHelper(Context ctx) {
  super(ctx, DATABASE_NAME, null, DATABASE_VERSION);
   }

   @Override
   public void onCreate(SQLiteDatabase db) {
  db.execSQL(CREATE TABLE  + TABLE_NAME +  ( + _ID
+  INTEGER PRIMARY KEY AUTOINCREMENT,  + NAME
+  TEXT NOT NULL););
   }

   @Override
   public void onUpgrade(SQLiteDatabase db, int oldVersion,
 int newVersion) {
  db.execSQL(DROP TABLE IF EXISTS  + TABLE_NAME);
  onCreate(db);
   }
   public void createRow(String name) {
   ContentValues initialValues = new ContentValues();
   initialValues.put(NAME, name);
  // initialValues.put(ADDRESS, address);
   //initialValues.put(MOBILE, mobile);
   //initialValues.put(HOME, home);
   db.insert(TABLE_NAME, null, initialValues);
   }
   public Cursor GetAllRows() {
   try {
   //Cursor c =
   return db.query(TABLE_NAME, new String[] {
   _id, name}, null, null, null, null, null);
   //return c;
   } catch (SQLException e) {
   Log.e(Exception on query, e.toString());
   return null;
   }
   }

}

-- 
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] gridview, array, xml

2009-12-30 Thread jasonwucinski
Hello everyone.  First, im new to developing for android and this
forum.  my question is this:  i was looking at the Hello world view:
gridview example and was wondering, how do i load all my images
dynamically.  for example in the ImageAdapter.java file, at the end
there is:
`private Integer[] mThumbIds = {
R.drawable.sample_2, R.drawable.sample_3,
R.drawable.sample_4, R.drawable.sample_5,
R.drawable.sample_6, R.drawable.sample_7,
R.drawable.sample_0, R.drawable.sample_1,
R.drawable.sample_2, R.drawable.sample_3,
R.drawable.sample_4, R.drawable.sample_5,
R.drawable.sample_6, R.drawable.sample_7,
R.drawable.sample_0, R.drawable.sample_1,
R.drawable.sample_2, R.drawable.sample_3,
R.drawable.sample_4, R.drawable.sample_5,
R.drawable.sample_6, R.drawable.sample_7
};`

but what if i dont know the images name (as the user will add new
images).  what i would like to do is grab the image name from an xml
file and then load it into an array.  how do i accomplish this?

thanks
jason

-- 
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: Issue with HelloWorld.

2009-12-30 Thread lkb
On my machine it has an android skin and the word menu, after the
android tool is completely activated, you can press on menu and a new
screen will show up with Hello Android.

BTW - The best way to see if you android (my_avd tool) has loaded
completely (it takes 5-10 minutest depending on your machine)
is to open the console window and you should see a set of messages
like:

This is what my says:
[2009-12-28 14:57:51 - HelloAndroid]Uploading HelloAndroid.apk onto
device 'emulator-5554'
[2009-12-28 14:57:51 - HelloAndroid]Installing HelloAndroid.apk...
[2009-12-28 14:58:26 - HelloAndroid]Success!
[2009-12-28 14:58:26 - HelloAndroid]Starting activity
com.example.helloandroid.HelloAndroid on device
[2009-12-28 14:58:30 - HelloAndroid]ActivityManager: Starting: Intent
{ comp={com.example.helloandroid/
com.example.helloandroid.HelloAndroid} }


On Dec 21, 6:04 am, Sanjeev iamsanj...@gmail.com wrote:
 Hi,
 I tried to execute a simple Hello World program, but the screen only shows
 ANDROID irrespective of what string I type. I am not sure how to fix this
 issue.

 I am following the code 
 inhttp://developer.android.com/guide/tutorials/hello-world.html

 package com.android.helloandroid;

 import android.app.Activity;
 import android.os.Bundle;
 *import android.widget.TextView;*

 public class HelloAndroid extends Activity {
    /** Called when the activity is first created. */
   �...@override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        *TextView tv = new TextView(this);
        tv.setText(Hello, Android);
        setContentView(tv);*
    }

 }

 No matter what I set the string I always see only ANDROID string on
 the simulator.

 Regards,
 Sanjeev

-- 
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] Eclipse/Android/Mac OS x problem with HelloAndroid

2009-12-30 Thread Planaria
Platform:  Mac OS X 10.5.8
Eclipse with latest Android ADT installed.

As far as I know, I followed all the installation directions to the
letter.

Create and try to run the HelloAndroid app.

I get the following error (last line):

[2009-12-28 13:28:30 - HelloAndroid]Android Launch!
[2009-12-28 13:28:30 - HelloAndroid]adb is running normally.
[2009-12-28 13:28:30 - HelloAndroid]Could not find HelloAndroid.apk!


Thanks in advance!
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: TabWidget Control

2009-12-30 Thread Toni
Hello,

Same problem here using:
eclipse 3.5
adt 0.9.5
target : android 1.5

Just copy past the code in the TabWidget tutorial (
http://developer.android.com/resources/tutorials/views/hello-tabwidget.html)
and I get the nullpointer on the layout view.

It's a bit freaky to get this kind of bug following a simple
tutorial...

-toni





On 7 déc, 18:25, Justin Anderson janderson@gmail.com wrote:
 Yes.  You have a null pointer.  Without code we can't help...

 --
 There are only 10 types of people in the world...
 Those who know binary and those who don't.
 --



 On Thu, Dec 3, 2009 at 6:32 AM, albertsmus alberts...@yahoo.com wrote:
  when i am in Eclipse and i modify tha main.xml file to add a TabWidget
  control in the layout design i get the following error on the form:
  NullPointerException : Null
  and the following error in Console Window
  [2009-12-03 15:24:51 - LunchList]1 error; aborting
  [2009-12-03 15:24:51 - LunchList]Conversion to Dalvik format failed
  with error 1
  java.lang.NullPointerException
         at android.widget.TabWidget.dispatchDraw(TabWidget.java:105)
         at android.view.ViewGroup.drawChild(ViewGroup.java:1434)
         at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1208)
         at android.view.ViewGroup.drawChild(ViewGroup.java:1434)
         at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1208)
         at android.view.ViewGroup.drawChild(ViewGroup.java:1434)
         at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1208)
         at android.view.View.draw(View.java:5465)
         at android.widget.FrameLayout.draw(FrameLayout.java:324)
         at
  com.android.layoutlib.bridge.Bridge.computeLayout(Bridge.java:338)
         at

  com.android.ide.eclipse.adt.internal.editors.layout.GraphicalLayoutEditor.c 
  omputeLayout
  (Unknown Source)
         at

  com.android.ide.eclipse.adt.internal.editors.layout.GraphicalLayoutEditor.r 
  ecomputeLayout
  (Unknown Source)
         at

  com.android.ide.eclipse.adt.internal.editors.layout.GraphicalLayoutEditor.o 
  nXmlModelChanged
  (Unknown Source)
         at

  com.android.ide.eclipse.adt.internal.editors.layout.LayoutEditor.xmlModelCh 
  anged
  (Unknown Source)
         at com.android.ide.eclipse.adt.internal.editors.AndroidEditor
  $XmlModelStateListener.modelChanged(Unknown Source)
         at

  org.eclipse.wst.sse.core.internal.model.AbstractStructuredModel.fireModelCh 
  anged
  (AbstractStructuredModel.java:553)
         at

  org.eclipse.wst.sse.core.internal.model.AbstractStructuredModel.internalMod 
  elChanged
  (AbstractStructuredModel.java:887)
         at

  org.eclipse.wst.sse.core.internal.model.AbstractStructuredModel.changedMode 
  l
  (AbstractStructuredModel.java:382)
         at
  org.eclipse.wst.xml.core.internal.document.DOMModelImpl.changedModel
  (DOMModelImpl.java:167)
         at
  com.android.ide.eclipse.adt.internal.editors.AndroidEditor.editXmlModel
  (Unknown Source)
         at

  com.android.ide.eclipse.adt.internal.editors.ui.tree.UiActions.addNewTreeEl 
  ement
  (Unknown Source)
         at
  com.android.ide.eclipse.adt.internal.editors.ui.tree.UiActions.addElement
  (Unknown Source)
         at
  com.android.ide.eclipse.adt.internal.editors.ui.tree.UiActions.doAdd
  (Unknown Source)
         at
  com.android.ide.eclipse.adt.internal.editors.ui.tree.UiActions.doAdd
  (Unknown Source)
         at
  com.android.ide.eclipse.adt.internal.editors.layout.UiContentOutlinePage
  $1.run(Unknown Source)
         at org.eclipse.jface.action.Action.runWithEvent(Action.java:498)
         at
  org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection
  (ActionContributionItem.java:584)
         at org.eclipse.jface.action.ActionContributionItem.access$2
  (ActionContributionItem.java:501)
         at org.eclipse.jface.action.ActionContributionItem$6.handleEvent
  (ActionContributionItem.java:452)
         at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
         at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1003)
         at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:
  3880)
         at
  org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3473)
         at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:
  2405)
         at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2369)
         at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2221)
         at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:500)
         at org.eclipse.core.databinding.observable.Realm.runWithDefault
  (Realm.java:332)
         at org.eclipse.ui.internal.Workbench.createAndRunWorkbench
  (Workbench.java:493)
         at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:
  149)
         at 

[android-beginners] Re: onSaveInstanceState behaving differently when rotating the screen and anything else

2009-12-30 Thread Syx
I get that. This is not the issue.  In both cases, the activity goes
through the same cycle and calls the same activity lifecycle methods.

Also, the exception comes from the onSaveInstanceState method when I
try to a Serializable object in the Bundle. I don't see how adding
anything to the other methods will help?

To explain better, this is what happens:

[Start the activity]
 .. onCreate()
 .. onStart()
 .. onResume()

[Rotate screen]
 .. onSaveInstanceState()
 .. onPause()
 .. onStop()
 .. onDestroy()
 .. onCreate()
 .. onStart()
 .. onResume()

[Rotate back]
 .. onSaveInstanceState()
 .. onPause()
 .. onStop()
 .. onDestroy()
 .. onCreate()
 .. onStart()
 .. onResume()

[Open a new activity in front of it or press home]
 .. onSaveInstanceState()
 --  java.lang.RuntimeException: Parcelable encountered IOException
writing serializable object
 --  Caused by: java.io.NotSerializableException

On Dec 23, 10:04 am, Nithin nithin.war...@gmail.com wrote:
  However, if either press home, or open another app in front of mine
  (eg, from the notification bar) then I get the following error:

 So, if you press home or open another activity through notification,
 your current Activity has lost focus and invisible, so it will be call
 onPause() and onStop() and open the new application. When coming again
 to your current Activity, its calling onRestart(), onStart() and
 onResume(). So you need to code accordingly.

 Nithin

 On Dec 22, 4:38 am, Syx syx...@googlemail.com wrote:



  Hi,

  So I have an app that downloads and displays a list of messages. I
  have two main classes that I use
   -  my own adapter which extends ArrayAdapter to display the list
  items in a specific way
   - and a mailbox class which has an ArrayList in it amongst other
  things

  Both of these classes implement Serializable.  In my
  onSaveInstanceState method, I have the following:

      @Override
      protected void onSaveInstanceState(Bundle outState) {
          super.onSaveInstanceState(outState);
          outState.putSerializable(savedAdapter, m_adapter);
          outState.putSerializable(savedMailbox, m_mailbox);
      }

  I have nothing in my onStart/onResume/onPause/onStop/onDestroy
  methods.  My onCreate method checks whether inState is null and does
  the appropriate thing.

  So here is my problem:

  When I rotate the screen, onSaveInstanceState() saves the all three
  objects, the activity is destroyed, recreated, and onCreate() extracts
  them all perfectly. Great.

  However, if either press home, or open another app in front of mine
  (eg, from the notification bar) then I get the following error:

  ERROR/AndroidRuntime(16961): java.lang.RuntimeException: Parcelable
  encountered IOException writing serializable object (name = my app
  $MessageAdapter)
  ...
  ERROR/AndroidRuntime(16961): Caused by:
  java.io.NotSerializableException: my app$3

  If I delete the relevant putSerializable line, then I get the same
  error for Mailbox.

  Why is it behaving in different ways when they are following exactly
  the same activity life cycle?
  And why would it throw an NotSerializableException at all when both
  classes implement serializable and work when I rotate the screen?

-- 
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: Application Idea, Need Assistance

2009-12-30 Thread ausstone
I think that this is a great idea...More applications need to be made
for the business.  Creating just one application should work just
fine.  Have you had any experience building apps? Do you have a team
together or looking to put one together?

On Dec 28, 1:18 am, StouteEnterprises paul.sto...@gmail.com wrote:
 I just started creating applications for the android system and am
 still very new to the programming. I would like to create an
 application for my sales staff that will do multiple things through
 the use of tabs. I'd like to have three tabs; Contacts, Sales, and
 Retention.

 Under the contact tab i would like it to list only the added contacts
 through the application, not all contacts on the device. I want to be
 able to add new contacts with the following information; First Name,
 Last Name, Home Number, Cell Number, Email Address, Home Address, and
 Notes. After entering the contact information into this application it
 would also save it to the phones contact list.

 Under the Sales tab I would like to have the ability to add any sales
 into the log. This tab would give the user the ability to view past
 sales, add new sales, delete sales, create queries for sales between
 chosen dates, and calculate commissions from these sales.

 Under the Retention Tab I would like it to create follow-up
 information based on the sale date and item sold. This would
 automatically enter a reminder or calendar appointment to contact the
 customer after 3 days, 1 month, and 1 year. This would also reference
 the customers contact information to Pop-Up the next time the
 application was opened after the callback period expired.

 This is a pretty complex application but I couldn't find anything
 similar to this in App. World and would like to get some help creating
 this application. I think this application is definitely well over my
 area of expertise. Even if I had to create three separate applications
 to make all of this work I would be fine with that.

 Thanks for all the help!

-- 
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: Just starting this, not working

2009-12-30 Thread mhulmenet
@amit --- unlock your phone by dragging the green lock (your
screenshot) to the right.

On Dec 18, 7:46 am, Amit Patel amit.sav...@gmail.com wrote:
 I waited about 2 minutes and now Home screen is displayed but Hello,
 Android isnotyet displayed.

 find the screenshot 
 herehttp://picasaweb.google.co.in/lh/photo/H4FakMjk323HCiapBgutOQ?feat=di...

 On Dec 7, 10:19 pm, Justin Anderson janderson@gmail.com wrote:



  Search the forums  This has been addressed SEVERAL times already!

  You are falling into one of two categories:

  1) You aren't waiting long enough for the emulator to load...  It can take
  anywhere from 30 seconds to hours depending on your computer configuration

  2) You really are having a problem with the emulator and even if you let it
  sit all night it still won't come up.  In that case I have read that some
  people think it may have to do with having an older video card but I have
  yet to see anything conclusive about the cause.

  --
  There are only 10 types of people in theworld...
  Those who know binary and those who don't.
  --

  On Wed, Dec 2, 2009 at 4:11 PM, airtaz airta...@gmail.com wrote:
   I installed the sdk and eclipse. I am attempting to follow the guide
   athttp://developer.android.com/guide/tutorials/hello-world.html. Im
  notgetting any notifications of errors. But my screen after running
   doesnotlook like the guide's. My screen opens up with a black
   section with the word Android in the middle of it, on the left side.
   And on the right side there are buttons consisting of a keyboard and
   above that other buttons relating to a phone.  Any ideas? I should
   point out tht setting up the ADT like they mention in the guide,
   doesn't work. I believe I managed to do it correctly via Eclipse.

   This is the exact code:

   package com.example.helloandroid;

   import android.app.Activity;
   import android.os.Bundle;
   import android.widget.TextView;

   public class HelloAndroid extends Activity {
      /** Called when the activity is first created. */
     �...@override
      public void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          TextView tv = new TextView(this);
          tv.setText(Hello, Android);
          setContentView(tv);

      }
   }

   --
   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.comandroid-beginners%2Bunsubscr
i...@googlegroups.com
   For more options, visit this group at
  http://groups.google.com/group/android-beginners?hl=en

-- 
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] Draw a dashed line on Canvas()

2009-12-30 Thread ROHIT
Hi, i am new developer in Android. How can we draw a dashed line on
Canvas()??

-- 
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] Over Lay Problem

2009-12-30 Thread ronnie173
Hi all I am new and I am trying to just make a simple gps application
that shows you what street your are on on the map. I am having a
problem with this piece of code.



positionOverlay = new MyPositionOverlay();
ListOverlay overlays = myMapView.getOverlays();
overlays.add(positionOverlay);

overlays.add(positionOverlay); is breaking the application when I add
it to the code. Anyone has a solution for this?

-- 
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] Regarding the flow of Browser in Android

2009-12-30 Thread prafull
Hi
I am new in Browser. I want to know the flow of the Browser from the
time we click on the Browser icon.
I was going through the scenario, Loading a URL. But the scenario is
not clear.
please help me.

-- 
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: Failed to reopen debug port for Selected Client to:

2009-12-30 Thread Spad
I too am running Debian and experiencing this problem after a recent
update.  I am using eclipse 3.5 (galileo) downloaded from the eclipse
website (rather than installed the package manager) and I am running
sun's java 6.

I added the following line to the eclipse.ini file:

-Djava.net.preferIPv4Stack=true

and after starting eclipse, I no longer experience the errors.

This also fixed the problems I was having connecting to sites with
Install New Software.

On Dec 21, 11:11 am, Kai Hendry kai.hen...@gmail.com wrote:
 I am experiencing the same problem on my Debian machine. I noticed it
 does not seem to be problem on Ubuntu. :/

-- 
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: Unable to see Google Map - but eveything else seems to be working....

2009-12-30 Thread ZhouSu
Hi Treking,

I obtained the MD5 fingerprint from debug.keystore and registered a
api-key. I believe I have properly set the INTERNET ,
ACCESS_COARSE_LOCATION permissions, uses-library and followed
everything else in the HelloMapView tutorial. But my app doesn't load
map tiles either. I have searched through the group and found many
people have the same problem but no solutions been given. Do you have
any clue where I got it wrong?

Thanks.

On Dec 8, 1:11 am, TreKing treking...@gmail.com wrote:
  I've set the debug.keystore.

 You don't set the debug.keystore ... that's already there as part of the
 SDK. You use that to get a hash value that you use on the maps api key
 signup page to get your debug key.

 I've verified I have them in the right place according to the Eclipse

 configuration.

 Setting up the maps API keys has nothing to do with Eclipse configuration.
 You add them to you mapview layouts (or set them in the map view constructor
 if you choose to do it in code).

 I'm thinking you might have mixed up some terms and not set this up
 properly.
 Go through the set
 uphttp://code.google.com/android/add-ons/google-apis/mapkey.html
 steps
 again. Make sure you have a debug key gained from the debug keystore and a
 release key gained from your release keystore and that you're using the
 correct one (the debug one in debug mode, the release one in release mode).

 Hope that helps.

 --- 
 --
 TreKing - Chicago transit tracking app for Android-powered 
 deviceshttp://sites.google.com/site/rezmobileapps/treking

 On Sun, Dec 6, 2009 at 9:14 AM, Steve Keener stevena.kee...@gmail.comwrote:



  I have an odd problem.  I'm working on my first Maps application.  I'm
  using the demo/tutorial code as a baseline to figure this out.

  I have the app running, I can see the zoom controlsbut no map
  graphic.

  I see no errors in the console.

  I've set the debug.keystore.  I also have the key for the API set.
  I've verified I have them in the right place according to the Eclipse
  configuration.

  I can even add an overlay with a small graphic with no problem.

  But I still only see the graph paper-like background for the map.
  I'm not sure what's going on.

  Using Java 1.6.

  Anybody have any ideas?  Thanks!

  Steve

  --
  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.comandroid-beginners%2Bunsubscr 
  i...@googlegroups.com
  For more options, visit this group at
 http://groups.google.com/group/android-beginners?hl=en

-- 
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


Re: [android-beginners] Problem with map display on emulator with kml file

2009-12-30 Thread Caius 'kaio' Chance
(2009年12月30日 14:10), wahib wrote:

 hi ! I am stuck with a mapview problem. I am running a simple
 application that shows a map view. When i load a kml file which is
 actually shows a running route , the map isnt displayed. The pointer
 keeps on moving in the direction set by route but the background is
 blank. I have no idea what is the issue. The mapkey is correct.


Sources please. :)

-- 
Caius 'kaio' Chance ☺ かいお
   Fedora Project Contributor http://fedoraproject.org/wiki/User:kaio
   kaio at fedoraproject.org, kaio on irc.freenode.net, GPG: 17BEFCFA

-- 
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] Images for spinner arrays

2009-12-30 Thread Duey Oxburger
Lads,

How can I make the spinner arrays images... (i.e. if I'm writing an
app to select different kinds of fruit, actually have images of fruit
show up in the array rather than text names...)

thx

Duey

-- 
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: Google Map is not displaying in emulator

2009-12-30 Thread ZhouSu
Have you solved this problem. My situation is the same and I can't
figure out why.

On Dec 9, 7:03 pm, san indlasrik...@gmail.com wrote:
 have an odd problem.  I'm working on my first Maps application.  I'm
 using the demo/tutorial code as a baseline to figure this out.

 I have the app running, I can see the zoom controlsbut nomap
 graphic.

 I see no errors in the console.

 I've set the debug.keystore.  I also have the key for theAPIset.
 I've verified I have them in the right place according to the Eclipse
 configuration.

 I can even add an overlay with a small graphic with no problem.

 But I still only see the graph paper-like background for themap.
 I'm not sure what's going on.

 Using Java 1.6.

-- 
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] emulator: ERROR: unknown virtual device name

2009-12-30 Thread jaesun
I am new to developing for Android.  And I am going with the Hello
World Example (http://developer.android.com/resources/tutorials/hello-
world.html).

Everything seems to be going fine, until I go to Run it to see the
results.  I get this error:

[2009-12-30 10:17:00 - HelloAndroid]--
[2009-12-30 10:17:00 - HelloAndroid]Android Launch!
[2009-12-30 10:17:00 - HelloAndroid]adb is running normally.
[2009-12-30 10:17:00 - HelloAndroid]Performing
com.example.helloandroid.HelloAndoird activity launch
[2009-12-30 10:17:00 - HelloAndroid]Automatic Target Mode: launching
new emulator with compatible AVD 'mytestavd2'
[2009-12-30 10:17:00 - HelloAndroid]Launching a new emulator with
Virtual Device 'mytestavd2'
[2009-12-30 10:17:00 - Emulator]emulator: ERROR: unknown virtual
device name: 'mytestavd2'
[2009-12-30 10:17:00 - Emulator]emulator: could not find virtual
device named 'mytestavd2'

I have tried creating AVDs using a different path, but to no avail.

when I go to list the AVDs (Candroid list avds in command prompt), i
get this:

Available Android Virtual Devices:
Name: mytestavd
Path: C:\jasonprojects\android\testavd
  Target: Android 1.5 (API level 3)
Skin: HVGA
-
Name: mytestavd2
Path: \\fn-archive\redirection$\jason.rider\.android\avd
\mytestavd2.avd
  Target: Android 1.5 (API level 3)
Skin: HVGA

I have tried setting an Environment Variable under System Variables:
ANDROID_SDK_HOME  == \\fn-archive\redirection$\jason.rider

(as the .android folder is located there)

but I cannot seem to get past this.

Any Help?

-- 
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: New to Java and Android

2009-12-30 Thread Tze Yun, Glenn Poh
Hi MWarren,

   I'm in a some what similar situation as you. Dunno if this helps
but you might want to look at the org.apache.http.client.methods
classes and methods... the part on HttpPost. Not sure how they work
but I'm still playing around with the code until i get a solution.
When i get it will share more with you. :)

On Dec 4, 9:48 am, MWarren mwarren3...@gmail.com wrote:
 Ok I need to start by saying I am new to Java and Android.  I am a web
 developer with my primary development is done in PHP.  I am trying to
 sort thru everything and set up an application for the new Droid
 running 2.0 but have trouble sorting thru the tutorials as they seem
 older.  What I am trying to create is basically a shell for a web app.
 I was hoping to be able to have a menu on the phone where I can set
 the webapp url(or could be stored in the program), username, password
 and api key and send the later 3 along with the geo-location to my
 webapp.
 Is this possible, can anyone provide me with assistance on this.

-- 
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] Contacts sync is not working

2009-12-30 Thread Onno
Hi,
I recentIy noticed that my contacts sync is not working anymore. When
I add a contact via gmail contacts it doensn't sync to my G1. I don't
know when it stopped working, I don't add contacts regularly and I
don't check often if the sync works. Actually I expected this to just
work and continue to work. I expect difficulties/problems sync with MS
Outlook but not with Google contacts. One of the reasons for wanting
this phone was the good integration with gmail, contacts, calendar.
This integration still needs a lot of work as it turns out.

Is this is a known issue that I am not aware of? I have googled for it
a bit but couldn't find much. Some suggest removing all contacts from
the G1 and then will work again. That seems like a risky approach if
sync is not working correctly. This implies that you might loose some
data. If you don't want to loose data I think the conclusion is that
you need to manually sync the contacts, create a backup, remove the
all contacts from the phone, drop to your knees and pray that sync
will start working again and that the contact information will appear
on your phone. Great! That is a sure two thumbs up for Google/Andriod/
Gmail.

Not sure what to do know. This all sounds like a lot of work. Maybe
I'll just accept that this is just not working.
Best Regards,
Onno

-- 
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] Getting different views in Tabs

2009-12-30 Thread tysmailbox
I have an app with 2 tabs, the first is a listview, and the second I'm
trying to make a TextView. The problem is I have no idea on how to get
the TextView to show up. The listview is working, but I can't get
anything on the TextView at all. I tried using the Hello, World to try
to work with the text into the tab, but I can't figure it out.

My main.xml section with the TabWidget looks like this:
-

TabWidget
android:id=@android:id/tabs
android:layout_width=fill_parent
android:layout_height=wrap_content /
FrameLayout
android:id=@android:id/tabcontent
android:layout_width=fill_parent
android:layout_height=fill_parent
ListView
android:layout_width=fill_parent
android:layout_height=fill_parent
android:id=@+id/itemlist /
TextView
android:id=@+id/HelloAndroid
android:layout_width=fill_parent
android:layout_height=fill_parent/
/FrameLayout

-
ListView is being used on the java file with the mTabHost code,
-

TabHost mTabHost = getTabHost();

mTabHost.addTab(mTabHost.newTabSpec(tab_test1).setIndicator
(Answer).setContent(R.id.itemlist));
mTabHost.addTab(mTabHost.newTabSpec(tab_test2).setIndicator
(Ask).setContent(R.id.HelloAndroid));

mTabHost.setCurrentTab(0);
}
-

The TextView is on a different file called HelloAndroid.java, and the
code looks like:
-

public class HelloAndroid extends Activity {
   /** Called when the activity is first created. */
   @Override
   public void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   TextView tv = new TextView(this);
   tv.setText(Hello, Android);
   setContentView(tv);
   }
}
-

How can I fix it so that the 2nd tab brings up the example text?
Thanks!

-- 
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: Eclipse Galileo Build path 1.6 Win XP Newbie

2009-12-30 Thread kaio
Check if you have the 'package' line of Java at the first line, rather
than your newly added comments.

I have same problem and finally figured out that this problem was
because of R.java and the .java files were not in 'same package'.

The layout and other xml files are similar: your comments could not
live beyond the root tag.

Hope this helps.

- kaio

-- 
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: SAX, XML, and odd results

2009-12-30 Thread Stefan


On Dec 30, 7:50 pm, Lovedumplingx lovedumpli...@gmail.com wrote:
 So I'm trying to add a list of files to a listview by parsing their
 names out of an XML file using the SAX parser.

 For some reason though I'm getting a blank data element inserted
 before my file name's are processed and I can't figure out why.

 My XML looks like:
 ?xml version=1.0?
 fileList
 filearch enemy - dead eyes see no future.mp3/file
 filetemp.jpg/file
 fileBaltimora - Tarzan Boy/file
 fileresearch_doc4.pdf/file
 /fileList

 My XML is well formed and here is the code I use to parse it:
 sp.parse(new InputSource(socket.getInputStream()), new DefaultHandler
 {
      public void characters(char ch[], int start, int length) throws
 SAXException
      {
           super.characters(ch, start, length);
           String xmlCharacterData = new String(ch, start, length);

           files.add(xmlCharacterData.trim());
       }

 });

Is this the full source? The characters(...) function gets the names
between an open and a close tag... perhaps he first find filename
and he look what text is in this tag (and this is empty!) and after
that he find the first file tag an there the parser finds the
names??
So  i think you need a boolean value like im_in_file_tag.. and if
the sax parser finds the first file tag you set this boolean value
to true and if the value is true, you can use your files.add
(xmlCharacterData.trim());


 Any thoughts?

-- 
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] emulator: ERROR note

2009-12-30 Thread powersil
Hello!
im runninf the Notepad tutorial.
at first, it ran OK . but now it suddenly started to say (when im
starting to run it) this message:

emulator: ERROR: system image file too large for device's hardware
configuration (74 MB  72 MB).


i'm running it on Eclipse  ,   ADT emulator. on Vista Home.

any idea's?

tankx

Powers

-- 
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: SAX, XML, and odd results

2009-12-30 Thread Lovedumplingx
So...in combination to what you said and something I read elsewhere
about SAX not handling UNICODE characters I found the issue was
because I had \n used in the creation of my file to make it readable
but alas...SAX was interpretting that as words.  So the issue was with
my XML creation.

Thanks for the thoughts though as I hadn't put 2 and 2 together.

On Dec 30, 2:03 pm, Stefan dahmenstef...@gmx.de wrote:
 On Dec 30, 7:50 pm, Lovedumplingx lovedumpli...@gmail.com wrote:





  So I'm trying to add a list of files to a listview by parsing their
  names out of an XML file using the SAX parser.

  For some reason though I'm getting a blank data element inserted
  before my file name's are processed and I can't figure out why.

  My XML looks like:
  ?xml version=1.0?
  fileList
  filearch enemy - dead eyes see no future.mp3/file
  filetemp.jpg/file
  fileBaltimora - Tarzan Boy/file
  fileresearch_doc4.pdf/file
  /fileList

  My XML is well formed and here is the code I use to parse it:
  sp.parse(new InputSource(socket.getInputStream()), new DefaultHandler
  {
       public void characters(char ch[], int start, int length) throws
  SAXException
       {
            super.characters(ch, start, length);
            String xmlCharacterData = new String(ch, start, length);

            files.add(xmlCharacterData.trim());
        }

  });

 Is this the full source? The characters(...) function gets the names
 between an open and a close tag... perhaps he first find filename
 and he look what text is in this tag (and this is empty!) and after
 that he find the first file tag an there the parser finds the
 names??
 So  i think you need a boolean value like im_in_file_tag.. and if
 the sax parser finds the first file tag you set this boolean value
 to true and if the value is true, you can use your files.add
 (xmlCharacterData.trim());





  Any thoughts?- Hide quoted text -

 - Show quoted text -- Hide quoted text -

 - Show quoted text -

-- 
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


Re: [android-beginners] Eclipse/Android/Mac OS x problem with HelloAndroid

2009-12-30 Thread Justin Anderson
Post the logcat info

On Dec 30, 2009 2:05 PM, Planaria m...@arguslab.com wrote:

Platform:  Mac OS X 10.5.8
Eclipse with latest Android ADT installed.

As far as I know, I followed all the installation directions to the
letter.

Create and try to run the HelloAndroid app.

I get the following error (last line):

[2009-12-28 13:28:30 - HelloAndroid]Android Launch!
[2009-12-28 13:28:30 - HelloAndroid]adb is running normally.
[2009-12-28 13:28:30 - HelloAndroid]Could not find HelloAndroid.apk!


Thanks in advance!
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.comandroid-beginners%2bunsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en

-- 
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] What is the best way to store non-editable preferancies

2009-12-30 Thread alexk-il

Hi,

Is it posible to define both editable and non-editable preferences
within the same preferences.xml file?

The following non-working example may illustrate what I am trying to
achieve:

PreferenceScreen
PreferenceCategory android:title=Player settings

CheckBoxPreference
  ...
  android:title=Continue from previous location
  android:summary=Yes/No
  ...
/

PreviousLocation 10min 10sec /PreviousLocation

/PreferenceCategory
/PreferenceScreen

The attribute PreviousLocation should not be either editable or
visible to user and it should be automatically stored by the
application instead.

What would be a correct way to achieve such a goal?

Thanks
Alex

-- 
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


Re: [android-beginners] What is the best way to store non-editable preferancies

2009-12-30 Thread Justin Anderson
Don't put anything in the xml file for it.  Use the SharedPreferences class
and programatically get/set the preference via key-value pairs...

I can provide some examples later if you need them, but am not in a position
right now to figure out the code.

Hope that helps,
Justin

--
There are only 10 types of people in the world...
Those who know binary and those who don't.
--


On Wed, Dec 30, 2009 at 6:28 PM, alexk-il
alexk.il.subscripti...@gmail.comwrote:


 Hi,

 Is it posible to define both editable and non-editable preferences
 within the same preferences.xml file?

 The following non-working example may illustrate what I am trying to
 achieve:

 PreferenceScreen
PreferenceCategory android:title=Player settings

CheckBoxPreference
  ...
  android:title=Continue from previous location
  android:summary=Yes/No
  ...
/

PreviousLocation 10min 10sec /PreviousLocation

/PreferenceCategory
 /PreferenceScreen

 The attribute PreviousLocation should not be either editable or
 visible to user and it should be automatically stored by the
 application instead.

 What would be a correct way to achieve such a goal?

 Thanks
 Alex

 --
 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.comandroid-beginners%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-beginners?hl=en


-- 
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] Adding additional activities to a project

2009-12-30 Thread Eno
Having used the SDK to generate a project and my main activity, Im
just wondering if there is a quick way in Eclipse to add additional
activities? Or do I use activitycreator? Or do I simply add the new
activity as a new class?


--

-- 
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] Scrolling list of clickable 'rows'

2009-12-30 Thread Eno
I want to implement a scrolling list where each row consists of an
image, a label and an icon arranged in a row. In addition I want to
make this whole row clickable so it opens a subactivity when clicked.
Im not sure which widgets I would employ to realize this?

Also, I want the main activity view to have a scrolling list but only
as part of the main display, so would I embed that scrolling list
inside a layout widget? If so, what interface would my activity
implement?


-- 
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


Re: [android-beginners] Adding additional activities to a project

2009-12-30 Thread Justin Anderson
I've only ever done it manually...

1) Create a new class that extends activity.
2) Add an entry in the manifest file for the new activity.

If there is some other way to do it, I would be interested in knowing as
well.  Not sure if I would use it or not (I generally don't like the way
code-generation tools write code) but I would at least like to play around
with it

--
There are only 10 types of people in the world...
Those who know binary and those who don't.
--


On Wed, Dec 30, 2009 at 8:51 PM, Eno symb...@gmail.com wrote:

 Having used the SDK to generate a project and my main activity, Im
 just wondering if there is a quick way in Eclipse to add additional
 activities? Or do I use activitycreator? Or do I simply add the new
 activity as a new class?


 --

 --
 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.comandroid-beginners%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-beginners?hl=en


-- 
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


Re: [android-beginners] Re: Issue with HelloWorld.

2009-12-30 Thread Caius 'kaio' Chance
(2009年12月29日 09:10), lkb wrote:
 On my machine it has an android skin and the word menu, after the
 android tool is completely activated, you can press on menu and a new
 screen will show up with Hello Android.

 BTW - The best way to see if you android (my_avd tool) has loaded
 completely (it takes 5-10 minutest depending on your machine)
 is to open the console window and you should see a set of messages
 like:

 This is what my says:
 [2009-12-28 14:57:51 - HelloAndroid]Uploading HelloAndroid.apk onto
 device 'emulator-5554'
 [2009-12-28 14:57:51 - HelloAndroid]Installing HelloAndroid.apk...
 [2009-12-28 14:58:26 - HelloAndroid]Success!
 [2009-12-28 14:58:26 - HelloAndroid]Starting activity
 com.example.helloandroid.HelloAndroid on device
 [2009-12-28 14:58:30 - HelloAndroid]ActivityManager: Starting: Intent
 { comp={com.example.helloandroid/
 com.example.helloandroid.HelloAndroid} }


 On Dec 21, 6:04 am, Sanjeeviamsanj...@gmail.com  wrote:
 Hi,
 I tried to execute a simple Hello World program, but the screen only shows
 ANDROID irrespective of what string I type. I am not sure how to fix this
 issue.

 I am following the code 
 inhttp://developer.android.com/guide/tutorials/hello-world.html

 package com.android.helloandroid;

 import android.app.Activity;
 import android.os.Bundle;
 *import android.widget.TextView;*

 public class HelloAndroid extends Activity {
 /** Called when the activity is first created. */
 @Override
 public void onCreate(Bundle savedInstanceState) {
 super.onCreate(savedInstanceState);
 *TextView tv = new TextView(this);
 tv.setText(Hello, Android);
 setContentView(tv);*
 }

 }

 No matter what I set the string I always see only ANDROID string on
 the simulator.

 Regards,
 Sanjeev


Is setContentView(tv); really loading tv you have created above, or 
loaded the tv.xml fron layout?

-- 
Caius 'kaio' Chance ☺ かいお
   Fedora Project Contributor http://fedoraproject.org/wiki/User:kaio
   kaio at fedoraproject.org, kaio on irc.freenode.net, GPG: 17BEFCFA

-- 
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


Re: [android-beginners] Re: Google Map is not displaying in emulator

2009-12-30 Thread me,Ramesh Yankati
Hi ,
You need to open port to internet access


Regards
Ramesh

On Wed, Dec 30, 2009 at 9:22 AM, ZhouSu zsmarga...@gmail.com wrote:

 Have you solved this problem. My situation is the same and I can't
 figure out why.

 On Dec 9, 7:03 pm, san indlasrik...@gmail.com wrote:
  have an odd problem.  I'm working on my first Maps application.  I'm
  using the demo/tutorial code as a baseline to figure this out.
 
  I have the app running, I can see the zoom controlsbut nomap
  graphic.
 
  I see no errors in the console.
 
  I've set the debug.keystore.  I also have the key for theAPIset.
  I've verified I have them in the right place according to the Eclipse
  configuration.
 
  I can even add an overlay with a small graphic with no problem.
 
  But I still only see the graph paper-like background for themap.
  I'm not sure what's going on.
 
  Using Java 1.6.

 --
 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.comandroid-beginners%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-beginners?hl=en


-- 
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


Re: [android-beginners] Re: Google Map is not displaying in emulator

2009-12-30 Thread Turnkey Builder
It's your maps key

On Dec 30, 2009 10:54 PM, me,Ramesh Yankati rameshyank...@gmail.com
wrote:

Hi ,
You need to open port to internet access


Regards
Ramesh

On Wed, Dec 30, 2009 at 9:22 AM, ZhouSu zsmarga...@gmail.com wrote:  
Have you solved this probl...

-- 
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] Configure Character Set Mode Android SMS

2009-12-30 Thread D1e6o!
Hello, I have a problem with the configurations of SMS in Android, In
my Country the default codification of SMS must be reduced, but
android is using the complete mode, in effect, when I try to put a
letter wich isn't in the alphabet of the reduced characters (as
example, ó, á, etc), the format changes directly to unicode and the
quantity of messages needed to send the same SMS is doubled or
tripled. Normally the option to configure this is in the SMS menu, but
here it isn't.
I'm using a motorola milestone with android 2.0 (is the droid version
for any countries)

Anybody have the solution to change this parameter?


Thanks!

-- 
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