YouAreAwesome
Lurker
Hi there lovely people,
First of all I want to say thank you for your time reading this.
I'm new to (Android) Programming, been following the Beginner's Tutorial on Udacity and I love it so far.
I have this weird bug happening to me.
I've been working in the activity_main.xml file to ad an picture to my app through the ImageView options.
It's in a RelativeLayout, and I've been adding the picture succesfully to the drawable folder.
I then asign the picture to the ImageView through the [android:src="@drawable/androidparty2"] attribute.
So it al works well. I can build the project succesful, and can launch it succesful on my phone. But after I close the VirtualDevice, the afore mentioned picture dissapears from the 'Design-menu' and all of a sudden the tag "@drawable/androidparty2" turns red in the XML file. (But I've didn't changed any code before or after I build/launched it).
I hope I described it good enough for you guys to understand.
The XML file as written in my file:
----
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity">
<ImageView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop"
android:src="@drawable/androidparty2"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="36sp"
android:fontFamily="sans-serif-light"
android:textColor="@android:color/white"
android:text="Happy Birthday Ben!"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"
android:textSize="36sp"
android:fontFamily="sans-serif-light"
android:textColor="@android:color/white"
android:text="From Me"
/>
-----
Thanks in advance for your reply, and have a good day!
Cheers!
First of all I want to say thank you for your time reading this.
I'm new to (Android) Programming, been following the Beginner's Tutorial on Udacity and I love it so far.
I have this weird bug happening to me.
I've been working in the activity_main.xml file to ad an picture to my app through the ImageView options.
It's in a RelativeLayout, and I've been adding the picture succesfully to the drawable folder.
I then asign the picture to the ImageView through the [android:src="@drawable/androidparty2"] attribute.
So it al works well. I can build the project succesful, and can launch it succesful on my phone. But after I close the VirtualDevice, the afore mentioned picture dissapears from the 'Design-menu' and all of a sudden the tag "@drawable/androidparty2" turns red in the XML file. (But I've didn't changed any code before or after I build/launched it).
I hope I described it good enough for you guys to understand.
The XML file as written in my file:
----
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity">
<ImageView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop"
android:src="@drawable/androidparty2"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="36sp"
android:fontFamily="sans-serif-light"
android:textColor="@android:color/white"
android:text="Happy Birthday Ben!"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"
android:textSize="36sp"
android:fontFamily="sans-serif-light"
android:textColor="@android:color/white"
android:text="From Me"
/>
-----
Thanks in advance for your reply, and have a good day!
Cheers!