Answer the question
In order to leave comments, you need to log in
How to navigate to a new Activity when selecting an item in a ListView?
Hello. I started learning how to program on android, and I ran into problems implementing some things in my first application (creating an application based on my existing knowledge, implementing new ones over time).
So here's what I want to implement: I have my Main Activity, there is a "Phones" button on it, clicking on which opens a list of manufacturers (Samsung, Apple, Google, etc.), and then clicking on "Samsung", for example , another list with phone models opens. And then choosing a model, information about it opens. But I can’t understand, having surfed the entire Internet, how to do it: firstly, the transition to a new Activity with a list of models, when selecting items in the first ListView, and secondly, how, without creating a large number of Activities, to implement those same screens with information about phone models.
Thank you!
Answer the question
In order to leave comments, you need to log in
<div class="wraper-block">
<div>12<br>texttext</div>
<div>12<br>text</div>
</div>
.wraper-block{
border:5px solid black;
display:flex;
justify-content:space-between;
}
.wraper-block div{
text-align:center;
}
Good afternoon,
A transition is created between the activity Intent object.
For your task, you will need to be familiar with lists
and list adapters. It is best to take turns taking a course of study . Specifically for this task - Chapter 5 and Chapter 7.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question