How to create a Bottom Navigation Bar in Android Studio (Kotlin 2020)

Поделиться
HTML-код
  • Опубликовано: 27 ноя 2024

Комментарии • 133

  • @muminoloruntola2146
    @muminoloruntola2146 4 года назад +4

    Can't still thank you enough. I started this language 2 weeks ago and I had a really weird problem with navigation bar.. Was about to sleep another third day of failure when your video came up thanks ..

  • @_angel_mohammadi3952
    @_angel_mohammadi3952 3 года назад +15

    This is exactly what I want from a youtube tutorial !!! Fast, easy, efficient and useful !!! Thanks a lot man, I love your work, keep the great work going ! It was very helpful for me

  • @this-is-bioman
    @this-is-bioman 3 года назад +5

    Excellent! That was helpful and without any unnecessary talk! I also love your clear pronounciation which is effortlessly easy to understand for non-native speakers.

  • @iJuce
    @iJuce 4 года назад +7

    this channel is a learning goldmine

  • @kevinyee9550
    @kevinyee9550 4 года назад +3

    Thanks for the tutorial, it's good to have an updated one on the subject. Android tools get updated so fast.

    • @Indently
      @Indently  4 года назад +2

      Agreed! I'll try to kee everything up to date on my channel!

  • @mondragondelgadomezlyzahor3260
    @mondragondelgadomezlyzahor3260 3 года назад +4

    YOU ARE MY HERO!!!! Gracias a ti pude salvar mi tarea :(

  • @davidandyka5760
    @davidandyka5760 11 месяцев назад +4

    excuse me, 4:44, where is this comes from (bottom_navigation), i got stuck at this one

  • @MarianoAltuna
    @MarianoAltuna 4 года назад +1

    your channel is the best I found, you are the best

  • @RahmatKhanZai89
    @RahmatKhanZai89 3 года назад

    Thanks a lot. I have fixed a issue watching this video.

  • @muminoloruntola2146
    @muminoloruntola2146 4 года назад +2

    You and Denis Panjuta are the best cause it was so easy to understand what you taught to me today. Could you make a video of a shopping application for food Please?...I'm missing some context and experience and I would be delighted to have your help

  • @aleixsolermarti5833
    @aleixsolermarti5833 4 года назад +1

    Bro thank you so much, I spend 3 days searching how the fk this shit works and u explained it in 5 min

  • @andrei8683
    @andrei8683 3 года назад +1

    perfect, quick and effective. Love such videos

  • @blessmewest
    @blessmewest 3 года назад +2

    thenks so much!!!!!!!!!!!!
    u saved me

  • @justinlin5235
    @justinlin5235 4 года назад +2

    Thanks for the tutorial. It’s really great!!

  • @Jlevk
    @Jlevk 2 года назад +2

    Main activity dont see my element bottom-navigation. And one more problem, i see bar in phone but xml is doesn't have it in studio

  • @rifqi458
    @rifqi458 3 года назад +1

    Damn, this is much simpler. Thank you

    • @Indently
      @Indently  3 года назад

      Hey Rifqi, no problem at all, I'm happy I could help!

  • @nykur9383
    @nykur9383 3 года назад

    Man you make it simple for me ty

  • @chubakv
    @chubakv 3 года назад +6

    I have problem with button_navigation. Cant call in MainActivity :(

    • @jeewanthalahiru2435
      @jeewanthalahiru2435 3 года назад +10

      findViewById(R.id.bottom_navigation).setOnNavigationItemSelectedListener {
      when(it.itemId){
      R.id.ic_home -> makeCurrentFragment(homeFragment)
      R.id.ic_favorite -> makeCurrentFragment(favoriteFragment)
      R.id.ic_setting -> makeCurrentFragment(settingFragment)
      }
      true
      }
      this works for me

    • @francoisch6856
      @francoisch6856 3 года назад +1

      @@jeewanthalahiru2435 Thank you so much!

    • @liztorres15
      @liztorres15 2 года назад

      El tiene la razón con si cogió, gracias

    • @Area-yy1xw
      @Area-yy1xw Год назад +1

      @@jeewanthalahiru2435 Life Saverrr! Thank youu! ❤❤❤

    • @JiggyJiggy21
      @JiggyJiggy21 7 месяцев назад

      @@jeewanthalahiru2435 omg, thank you so much! I had the same issues couldn't find out why.

  • @whitemamba00
    @whitemamba00 3 года назад +1

    Hello, Thank you for great tutorial, I have a question, for example what if I only want to resize Favorites part, how to I change size of this icon ? I can resize all of them but I can't resize one of them, thanks.

  • @muhammadcandraalifisya265
    @muhammadcandraalifisya265 3 года назад

    you are my hero dude

  • @winnuayi3266
    @winnuayi3266 3 года назад +1

    simple and straight to the point.

  • @shubhamnaik1982
    @shubhamnaik1982 3 года назад +2

    Bhai, full sequential course banayo na Kotlin for Android ke liye.

  • @pixelPlaygourd
    @pixelPlaygourd 3 года назад +1

    Osm

  • @juliocamacho6298
    @juliocamacho6298 3 года назад +1

    Excellent thanks

  • @jonathanestrada1687
    @jonathanestrada1687 4 года назад

    You help me a lot, thank you!! ♥️

  • @zethbox8619
    @zethbox8619 2 года назад +1

    Doesn't display the bottom navigation bar for me

  • @omarvelasco1682
    @omarvelasco1682 3 года назад

    You are the best

  • @marymaria5865
    @marymaria5865 3 года назад +1

    good job

  • @rasarodchawang2340
    @rasarodchawang2340 4 года назад +1

    Thank you very much.
    ❤❤❤

  • @PMTFILMS
    @PMTFILMS 3 года назад +2

    when i was in the final stage of writing the code in the mainactivity.kt the val functions after the = sign were all red

    • @Indently
      @Indently  3 года назад

      try findviewbyid

    • @PMTFILMS
      @PMTFILMS 3 года назад

      @@Indently would i put this in the main activity?

    • @swethaaresetty3105
      @swethaaresetty3105 3 года назад

      @@PMTFILMS TRY THIS
      val bottom_Navigation = findViewById(R.id.bottom_navigation) as com.google.android.material.bottomnavigation.BottomNavigationView

      bottom_Navigation.setOnNavigationItemReselectedListener { }
      }

  • @kleber0a0m
    @kleber0a0m Год назад

    Muito bom o vídeo, ajudou bastante. Obrigado =)

  • @jookim3403
    @jookim3403 4 года назад +1

    You save me !! tks !!

  • @phonegames2857
    @phonegames2857 4 года назад +1

    thx sooooooooo much bro

  • @cosmostv8296
    @cosmostv8296 4 года назад +1

    thanks Federico Cotogno

  • @androidmillennium9266
    @androidmillennium9266 2 года назад

    Thanks a lot

  • @sb-dor
    @sb-dor 2 года назад

    Please answer my question.
    Why do these buttons work only after double-clicking ?

  • @Prod.JXXN.
    @Prod.JXXN. 4 года назад

    Nice video!

  • @hanadanefa7837
    @hanadanefa7837 4 года назад +1

    how can i make an extended floating action button on the fragment let say on home fragment that you create? and put some toast after clicking the extended floating action button

  • @D3r_3k_
    @D3r_3k_ 4 года назад +1

    Thank you very much, it worked for me !!
    You could make a video explaining how to make a Drawer Menu that opens fragments and has its return button in the toolbar
    You have earned a new subscriber!

    • @Indently
      @Indently  4 года назад +1

      I'll work on it! Thanks for the support!

  • @HuanNguyen-np9uw
    @HuanNguyen-np9uw 4 года назад

    lovely tutorial, tks

  • @robertlaguna3503
    @robertlaguna3503 3 года назад +2

    man i have a problem, can you please help me?
    when i use the setOnNavigationItemSelectedListener android studio does not recognize the id of my bottom navigation bar and it just doesn't work
    i already checked all my code and its the same

  • @ethiomusic3158
    @ethiomusic3158 3 года назад

    It is good tutorial. But you rushed highly. I did all but when I click the icons, the app goes wrong and disappear from the emulator. And when I remove the fragments, I can see the icons but they don't listen at all. And the other thing is, I couldn't get the titles with the icons. Why? Android Studio couldn't detect me where I missed it. Please help me.

  • @racoon_yt
    @racoon_yt 2 года назад

    My setOnNavigationItemSelectedListener is crossed out, help please

  • @bismoaghna5407
    @bismoaghna5407 3 года назад +4

    why button_navigation cant call in MainActivity ? its red

    • @finnk2012
      @finnk2012 3 года назад +1

      im having the same problem

    • @chubakv
      @chubakv 3 года назад +1

      @@finnk2012 and I

    • @swethaaresetty3105
      @swethaaresetty3105 3 года назад +1

      TRY THIS
      val bottom_Navigation = findViewById(R.id.bottom_navigation) as com.google.android.material.bottomnavigation.BottomNavigationView

      bottom_Navigation.setOnNavigationItemReselectedListener { }
      }

    • @swethaaresetty3105
      @swethaaresetty3105 3 года назад

      @@finnk2012 TRY THIS
      val bottom_Navigation = findViewById(R.id.bottom_navigation) as com.google.android.material.bottomnavigation.BottomNavigationView

      bottom_Navigation.setOnNavigationItemReselectedListener { }
      }

    • @liew0328
      @liew0328 3 года назад

      @@swethaaresetty3105 It's working. Thank you so much :)

  • @lunsim
    @lunsim 2 года назад

    Could you apply lottie animation into BottomNavigationView using navigation graph?

  • @riyazmohamed6532
    @riyazmohamed6532 2 года назад +1

    what is itemid in main activity

  • @thealchemist6445
    @thealchemist6445 4 года назад +1

    Awseome quick..

  • @SpainTecno
    @SpainTecno 2 года назад

    If in each option of the navigation bar there are different fragments, how can you make that when you click on an option of the navigation bar, it returns to the main fragment instead of staying in the last fragment?

  • @axedexango
    @axedexango 4 года назад

    Hello nice tutorial, but i have a question how i replace a fragment when i click in a button on home_fragment?

    • @Indently
      @Indently  4 года назад +1

      I recommend searching the navigation component which is part of the new Android recommended architecture components. It makes life easy

    • @axedexango
      @axedexango 4 года назад

      @@Indently ok thanks

  • @kennyargentokennyargento2676
    @kennyargentokennyargento2676 4 года назад +5

    Thanks for this video, very interesting! but... i have problem in the 04:45 minutes,
    the error messege is Unresolved reference: itemId:
    when (it.itemId){
    can you help me please??
    thanks you so much

  • @hanadanefa7837
    @hanadanefa7837 4 года назад

    Can you make also a tutorial regarding In App Purchase, where the case is the sells 10gold and 100gold, can you make a tutorial of it?

  • @brandanjong3092
    @brandanjong3092 4 года назад +1

    Hi, I've followed the whole tutorial I can see the bottom navigation icons in my physical device. However when I click on them they stay in one fragment e.g. when I click on settings it still shows the text Home. And I have changed the text to say settings. But still its not changing everytime I run the app.
    Thanks

    • @janniscodingroom4357
      @janniscodingroom4357 4 года назад +2

      Check if you surely used the "setOnNavigationItemSelectedListener" and not the "Reselected" one.

  • @DNightmareGT
    @DNightmareGT 3 года назад

    yo, i am using the pop up navigation menu which is kinda standard (the left navigation menu), so the issue i am facing is when i click one of the navigation, it does work but it doesnt close upon clicking, any solution for it?

    • @Indently
      @Indently  3 года назад

      Hey, I wouldn't be able to answer that without doing some research on Google. Have you already tried writing the same question on Google?

    • @DNightmareGT
      @DNightmareGT 3 года назад

      @@Indently yo, just figured it out tho, i could just add {} in the navigations and it actually worked

  • @kissgergo5202
    @kissgergo5202 Год назад

    Could someone explain how to do it with activites instead of fragments?

  • @jeewanthalahiru2435
    @jeewanthalahiru2435 3 года назад +1

    bottom_navigation cannot be called in MainActivity, is there any import mechanism or something for do that?

    • @Frank-zv4up
      @Frank-zv4up 2 года назад

      you ever got this resolved?

    • @jeewanthalahiru2435
      @jeewanthalahiru2435 Год назад +1

      @@Frank-zv4up findViewById(R.id.bottom_navigation).setOnNavigationItemSelectedListener {
      when(it.itemId){
      R.id.ic_home -> makeCurrentFragment(homeFragment)
      R.id.ic_favorite -> makeCurrentFragment(favoriteFragment)
      R.id.ic_setting -> makeCurrentFragment(settingFragment)
      }
      true
      }
      this works for me

  • @hanadanefa7837
    @hanadanefa7837 4 года назад

    thanks for this tutorial, but i don't know why mine behaves different,

  • @phantom2046
    @phantom2046 4 года назад

    supportFragmentManager is not being recognized (Unresolved reference: supportFragmentManger)
    what can be the problem?

  • @acunningclown
    @acunningclown 3 года назад

    How do you change the font size of the bottom navigation menu?

  • @josephchizororo3460
    @josephchizororo3460 3 года назад +1

    great video, thank you very much!!!! if anyone can help me please. i am having a problem on the MainActivity.kt. My bottom_navigation.setOnNavigationItemSelectedListner line is coming up as an unresolved reference for bottom_navigation. anyone know what the problem might be?

    • @Indently
      @Indently  3 года назад

      use findviewbyid

    • @swethaaresetty3105
      @swethaaresetty3105 3 года назад

      TRY THIS
      val bottom_Navigation = findViewById(R.id.bottom_navigation) as com.google.android.material.bottomnavigation.BottomNavigationView

      bottom_Navigation.setOnNavigationItemReselectedListener { }
      }

  • @mondragondelgadomezlyzahor3260
    @mondragondelgadomezlyzahor3260 3 года назад +1

    TE AMO TE AMO TE AMO TE AMO

  • @hanadanefa7837
    @hanadanefa7837 4 года назад

    And a floating window, that draw over other app? Its like the app is on top of another app

  • @tnnz9920
    @tnnz9920 3 года назад

    Sir how to make it floating on scroll view?

  • @alienalien9288
    @alienalien9288 4 года назад

    hi, does it matter what implementation verson u user for material? like u use 1.1.0 but could i use 1.2.0-beta01?

    • @Indently
      @Indently  4 года назад

      I haven't tried, but it should work the same unless they explicitly updated something in the documentation. But just try it out!

    • @alienalien9288
      @alienalien9288 4 года назад +1

      @@Indently hi, thx and imma try it out btw quick response :) nice!

    • @alienalien9288
      @alienalien9288 4 года назад

      @@Indently hey code palace, i have a problem, so in one of my fragments i created a logout textview but how do i make it so it makes me go to another activity from an onclicklistener?

  • @Peter-Petes
    @Peter-Petes 4 года назад

    Can a fragment hold RecylerView while using bottom navigation Bar ?

  • @ronanirvine9910
    @ronanirvine9910 3 года назад

    I cant seem to get the "bottom_navigation.setOnNavigationItemSelectedListener" part to work, it just turns red for not good reason

  • @eldinpita
    @eldinpita 3 года назад

    This was great! however for some reason on the bottom bar, The icons are showing up, but only under the Home Icon does it say "Home" under the other icons there is no writing. Anyone come up with that issue?

  • @chiragkumar1968
    @chiragkumar1968 4 года назад

    My bottom navigation hiding behind back/home button layout. What to do?

    • @Indently
      @Indently  4 года назад

      Type it in google

    • @MiYakudzik
      @MiYakudzik 4 года назад

      Maybe you chased wrong Layout type?

  • @lifedreamtv
    @lifedreamtv 4 года назад

    I also have a probelm - makeCurrentFragment is unresolved :(

  • @BillyLegumbres
    @BillyLegumbres 2 года назад

    But what if i want to move from activity to activity with it

    • @Indently
      @Indently  2 года назад

      We’re sorry to hear that you’re facing trouble with this tutorial. We have some suggestions for you:
      - First, try watching the tutorial again to check if you missed something (remember that programming languages are strict, and that uppercase & lowercase characters are completely different.)
      - Second, if you’re facing an error, try copying and pasting it into the Google search engine, it’s the fastest way to find the best response for the issue you are facing.
      - Third, if it’s still too confusing for you, try taking a step back and working on an easier project to try to improve your programming skills before tackling the project in this video.
      We wish you the best of luck with your project!

  • @sebastiangortz1888
    @sebastiangortz1888 4 года назад

    Hey can you maybe help me?
    would be really nice from you :)
    Here's the problem:
    I copied the code exactly the same way and yet the pages do not link to me.
    Even if I choose a "fragment (blank)" I cannot select the things from / to which you can (inclode fragment factory methods? Or crear layout XML?) Maybe that is the problem.

    • @Indently
      @Indently  4 года назад

      Hey Sebastian! I can't help with the amount of information provided, but I definitely recommend asking on Stack Overflow. Either you missed a very small detail, or it could be something else. Thanks for commenting :)

  • @theguywithatimemachine436
    @theguywithatimemachine436 4 года назад

    How can i implement the bottom navigation on a fragment because i have the navigation drawer on the main activity thanks in advance

    • @Indently
      @Indently  4 года назад

      I would have to do some research, but can't you just use layout_above or something in the XML so everything gets placed above the navigation bar?

    • @theguywithatimemachine436
      @theguywithatimemachine436 4 года назад

      @@Indently i never thought of that i have to try it out thanks

    • @muminoloruntola2146
      @muminoloruntola2146 4 года назад

      @@theguywithatimemachine436 Did it work?

    • @theguywithatimemachine436
      @theguywithatimemachine436 4 года назад

      @@muminoloruntola2146 yes i managed to archive this but i did it using java

    • @muminoloruntola2146
      @muminoloruntola2146 4 года назад

      @@theguywithatimemachine436 Oops I don't know java.

  • @Genio7781
    @Genio7781 3 года назад

    Could you convert this into Java?

    • @Indently
      @Indently  3 года назад

      Kotlin automatically converts this into Java already, try Kotlin.

  • @gagasnusa6015
    @gagasnusa6015 4 года назад +1

    Why i cant call my bottom navigation id?

    • @Indently
      @Indently  4 года назад

      good question

    • @gagasnusa6015
      @gagasnusa6015 4 года назад

      @@Indently thanks, case solved🎉

    • @pulkitarora2472
      @pulkitarora2472 4 года назад

      how did u solve it i am having same problem

    • @mohamednoemancoutry3664
      @mohamednoemancoutry3664 4 года назад

      @@Indently Me too can you explain to me how can I call it

    • @swethaaresetty3105
      @swethaaresetty3105 3 года назад

      @@gagasnusa6015 TRY THIS
      val bottom_Navigation = findViewById(R.id.bottom_navigation) as com.google.android.material.bottomnavigation.BottomNavigationView

      bottom_Navigation.setOnNavigationItemReselectedListener { }
      }

  • @ProgrammerTimes
    @ProgrammerTimes Год назад

    great work bro i have created similar video on my channel if you have time do check it

  • @telintservicio
    @telintservicio 2 года назад

    wtf programming at Kotlin is fastest :O :O :O

  • @Kiko-glitching
    @Kiko-glitching 2 года назад

    his in a hurry

  • @codewithsas
    @codewithsas 2 года назад

    Thank you so much