I've tried including date and time pickers in the XML file, like the following:
<DatePicker xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="wrap_content" android:layout_height="wrap_content" /> <TimePicker android:id="@+id/wtb_event_time" android:layout_width="wrap_content" android:layout_height="wrap_content" /> But I get: ERROR/AndroidRuntime(2930): Caused by: java.lang.RuntimeException: Binary XML file line #40: You must supply a layout_width attribute. ERROR/AndroidRuntime(2930): at android.content.Resources $StyledAttributes.getLayoutDimension(Resources.java:1247) ERROR/AndroidRuntime(2930): at android.view.ViewGroup $LayoutParams.setBaseAttributes(ViewGroup.java:2641) ERROR/AndroidRuntime(2930): at android.view.ViewGroup $LayoutParams.<init>(ViewGroup.java:2605) ERROR/AndroidRuntime(2930): at android.view.ViewGroup.generateLayoutParams(ViewGroup.java:2101) ERROR/AndroidRuntime(2930): at android.view.ViewInflate.inflate(ViewInflate.java:358) ERROR/AndroidRuntime(2930): at android.view.ViewInflate.inflate(ViewInflate.java:292) ERROR/AndroidRuntime(2930): at android.view.ViewInflate.inflate(ViewInflate.java:241) There is a layout_width attribute, so what's wrong? I've tried putting only one of those views inside of a layout file, and even if the Eclipse Android project doesn't complain, the emulator does. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---