Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8492779
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T22:49:17+00:00 2026-06-10T22:49:17+00:00

I am new to Android development. Is it fine to use the same ID

  • 0

I am new to Android development. Is it fine to use the same ID for images and TextViews in different Layout XML files?

When eclipse auto-list them for me, it lists all the layout variables from the project, so will it collide? Till now I have not noticed any problems using the same ID in different layouts, but I am concerned in long run.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T22:49:19+00:00Added an answer on June 10, 2026 at 10:49 pm

    It is recommended that you use different ids for different layouts. On the long run, when you will have a lot of layouts and therefor a lot of ids it will get very complicated to differentiate them.

    I usually name my ids like this: layoutName_elementId.

    It works for me to easily find the id I’m looking for, especially when using autocomplete (I know on what layout I’m working, but I don’t really know the id; in this case, with my naming strategy, I only type the layout name and it brings on all the ids of that layout).

    More information on layouts and ids can be found here.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i am new to android development. I am use the following code to set
Im new to android development. Now im trying to use sqlite db. I created
Im new to android development. Now im trying to use sqlite db. I created
I am new to android development. If I have more than one xml file,
I am new to java, eclipse, and android development, so I may be missing
As I am new to Android development, I have used SAX xml parsing in
I am new to Android development. I have both Windows 7 and Mac OS
I'm new to Android development and was playing around with the camera. I just
I am somewhat new to android development and development in general. I have a
I am new to android development . I'm trying to download and run the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.