The MainActivity.kt recieve the latitude and longtitude
val intent = Intent(this@MainActivity,MapsActivity::class.java)
intent.putExtra("latitude", latitude)
intent.putExtra("longitude", longitude)
And then pass to MapsActivity.kt
val intent = Intent(this@MapsActivity,MainActivity::class.java)
val lat=intent.getStringExtra("latitude").toDouble()
val lon=intent.getStringExtra("longtitude").toDouble()
And when I run the application I get a errors while I go to MapsActivity
What is the main cause of this problem and how can I pass the values in the correct way?