Thank you very much, the author of the video, I sat for 3 days and could not set up this navigation, reviewed different videos, re-read the instructions from Google 20 times, But after watching this video I succeeded, many thanks to the author
I also want to add to access the fragment, you can use the following val button: Button = view.findViewById(R.id.fragmentABtn) and then just button.setOnClickListener
Any chance you could do this in Java as well? I've had trouble from 12:55, in Java, there is a class that has the setupActionBarWithNavController, and I tried having my MainActivity implement it, but it didn't work. Such big differences between java and kotlin seem counter-intuitive to me. Perhaps I am doing something wrong.
for new android studio edition .. how to connect your fragment view on activity main val hostFragment = supportFragmentManager.findFragmentById(R.id.fragment) as NavHostFragment val controller = hostFragment.navControlle
for new android studio edition .. how to connect your fragment view on activity main val hostFragment = supportFragmentManager.findFragmentById(R.id.fragment) as NavHostFragment val controller = hostFragment.navController
I followed the steps but in the part of adding fragmentABtn.setOnClickListener, the fragmentABtn is not showing and turning to red. I don't know what is missing.
I don't understand how he got the button in the first place, maybe he is using a Kotlin feature that was deprecated, but you can use the findviewbyid to get the button first. I'm not sure, but I think it would be: val fragmentABtn: Button = view.findViewById(R.id.fragmentABtn) Then you can use the button
I don't understand how he got the button in the first place, maybe he is using a Kotlin feature that was deprecated, but you can use the findviewbyid to get the button first. I'm not sure, but I think it would be: val fragmentABtn: Button = view.findViewById(R.id.fragmentABtn) Then you can use the button
@@carlosarena9864 thanks for the reply and yes he was using kotlin Synthetics which was deprecated recently and it took me hours to find that..... then I implemented viewBinding in my project :)
In FragmentA -> btn click scenario --> How to handle recyclerview onclick in main fragment using interface. override fun onItemClick(data: Data) { Navigation.findNavController(view).navigate(R.id.action_putAwayFragment_to_enterDimensionsFragment) } facing issue with view
Thank you very much, the author of the video, I sat for 3 days and could not set up this navigation, reviewed different videos, re-read the instructions from Google 20 times, But after watching this video I succeeded, many thanks to the author
I also want to add to access the fragment, you can use the following val button: Button = view.findViewById(R.id.fragmentABtn) and then just button.setOnClickListener
Mine doesnt work 😢 there is no error but still nothing happen when i clicked on the buttons
I LOVE YOU SOOO MUCH, LITERALY STRUGLED FOR THIS 4 DAYS , THANK YOUUU
The best tutorial for the new (and confusing) navigation drawer.
you're literally my day saviour
This was the best tutorial I watched. 🖐
Simple and clear explanation love from pakistan
Thank you! Welcome to our community! Looking forward to seeing you around!
Any chance you could do this in Java as well? I've had trouble from 12:55, in Java, there is a class that has the setupActionBarWithNavController, and I tried having my MainActivity implement it, but it didn't work. Such big differences between java and kotlin seem counter-intuitive to me. Perhaps I am doing something wrong.
for new android studio edition .. how to connect your fragment view on activity main
val hostFragment = supportFragmentManager.findFragmentById(R.id.fragment) as NavHostFragment
val controller = hostFragment.navControlle
@@lover1301 in the example, you need to put "fragmentContainerView" instead of "fragment"
for new android studio edition .. how to connect your fragment view on activity main
val hostFragment = supportFragmentManager.findFragmentById(R.id.fragment) as NavHostFragment
val controller = hostFragment.navController
Excellent tutorial, to the point the concise, thank you..
I followed the steps but in the part of adding fragmentABtn.setOnClickListener, the fragmentABtn is not showing and turning to red. I don't know what is missing.
I don't understand how he got the button in the first place, maybe he is using a Kotlin feature that was deprecated, but you can use the findviewbyid to get the button first. I'm not sure, but I think it would be:
val fragmentABtn: Button = view.findViewById(R.id.fragmentABtn)
Then you can use the button
Thank you so much for this great tutorial I was watching this Concept on Udacity but tbh this one is better good job 👏
I took a course in Udacity but it was terrible I didn't understand anything and everything was fast without explaining a lot of things
nice video. thanks !
thanks man ... a lots of thanks
Thank You for sharing, it is very useful for me as a student
Thanks huge help
I couldn't set onclicklistener on the button , i followed the video exactly but studio was not detecting my button
I don't understand how he got the button in the first place, maybe he is using a Kotlin feature that was deprecated, but you can use the findviewbyid to get the button first. I'm not sure, but I think it would be:
val fragmentABtn: Button = view.findViewById(R.id.fragmentABtn)
Then you can use the button
@@carlosarena9864 thanks for the reply and yes he was using kotlin Synthetics which was deprecated recently and it took me hours to find that..... then I implemented viewBinding in my project :)
@@carlosarena9864 Thank you bro i spent 2 days i wish i read your comment earlier you saved me
great sir plz keep going
Thank you! I will release the second part in few days! Stay tuned!
it's great video man)))
I am glad that you liked it!
im sure your chanel will grows soon your tutorials are great
Thank you! It means a lot!
Great! Thank you!
Glad that you liked it!
In FragmentA -> btn click scenario --> How to handle recyclerview onclick in main fragment using interface. override fun onItemClick(data: Data) {
Navigation.findNavController(view).navigate(R.id.action_putAwayFragment_to_enterDimensionsFragment)
}
facing issue with view
Thanks Bother
You welcome! Glad that you liked it!
It doesnt work.......
This is not for dummies.. in AndroidStudio how to get to this navigation screen.... so after 10 seconds I hook of and search a better video.
thats great sir , please upload more android development tutorials
More awesome tutorials are coming so stay tuned!