1

I really don't know the reason behind this. In this block of code.

    <ProgressBar
      android:id="@+id/progressBar"
      style="@android:style/Widget.Pbar"
      android:layout_width="fill_parent"
      android:layout_height="wrap_content"
      android:layout_alignParentTop="true"
      android:layout_alignStart="@id/imgFrame"
      android:layout_gravity="center_vertical"
      android:layout_marginTop="15dp"
      android:indeterminate="true" />

The error is always on this part. It states that error: No resource identifier found for attribute 'layout_alignStart' in package 'android' .

This error sometimes disappear but then again appears. This was a big problem because i can't generate R.java because of the error on this part in res. So i tried commenting it out to be able to generate R.java. And then when i try to run the application, it will take too much time and then prompts an error encountered. This project is an existing source which I imported/ added new project from existing source.

sftdev
  • 1,701
  • 3
  • 16
  • 18

4 Answers4

1

Please replace layout_alignStart with layout_alignLeft. They have the same effect on the view.

Libera Me
  • 63
  • 1
  • 2
  • 9
0

Replace @+id for @id, see the differece here

Basically @+id is to generate a new entry at compile time to R.java file while @id is to reference an existing one. You are trying to align your item respect to another one that already exist.

android:layout_alignStart="@id/imgFrame"

Community
  • 1
  • 1
AlexBcn
  • 2,450
  • 2
  • 17
  • 28
  • yup, i know the difference between the two. I've just imported it and i've already noticed that one and already changed it. Still, nothing.. – sftdev May 15 '13 at 07:23
0

layout_alignStart is defined only for RelativeLayout

GVillani82
  • 17,196
  • 30
  • 105
  • 172
0

just cut the line layout_alignStart="" the error will gone

usama
  • 1