0

I have a long android layout xml.

how can I extract a linearlayout in it to another file?

how is the including convention?

I'm using eclipse

1

4 Answers 4

2

add this to ur another file under layout..

 <include layout="@layout/urfirstlayout"/>

Reference: Check this link for more info

Sign up to request clarification or add additional context in comments.

Comments

1

Click on you xml layout then >> Extract Include..

you able to Extract layout and automatically include in parent layout.

Thanks

Comments

1

You should use < include > tag:Re-using Layouts with include

Comments

0

Check out this link: http://developer.android.com/training/improving-layouts/reusing-layouts.html Basically if you save your layout in titlebar.xml Include it like this: <include layout="@layout/titlebar"/>

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.