PDA

View Full Version : HelloGallery tutorial: android.R.styleable cannot be resolved



ppmoore
03-23-2009, 12:55 PM
Hello,

I've been following the Views tutorials included in the android developer site:
http://developer.android.com/guide/tutorials/views/hello-gallery.html

When testing the "Hello Gallery" view, I get the compile-time error:
"android.R.styleable cannot be resolved"

I searched for this error on this group but is wasn't answered.
Can anyone help?

The problem reference occurs in the imageAdapter class that is appended after the onCreate() method in the HelloGallery class:

public class ImageAdapter extends BaseAdapter
{
...
TypedArray a = obtainStyledAttributes(android.R.styleable.Theme);
}

Strangely enough, when I insert this line into the onCreate() method at the start of the package, there is no problem. It seems that the android.R class is not known to this class.

Thanks,

g1ftmfw
03-23-2009, 01:34 PM
go over to xda and ask the questions you have

ppmoore
03-24-2009, 05:38 AM
Question: what is "xda"? An android-specific forum?

Thanks,
Paul

divestoclimb
03-24-2009, 10:27 AM
http://forum.xda-developers.com/forumdisplay.php?f=448