Such as title.Implicit intent can be used in startActivity,how to be used in startActivityForResult?
- Create Singleton class for application instance for example :
class MyApp: Application() {
override fun onCreate() {
super.onCreate()
instance = this
}
companion object {
lateinit var instance: MyApp
private set
}
}
- then after call it where you required application object instance. for example :
val intent: Intent = Intent(MyApp.instance, DestinationActivity::class.java);
MyApp.instance.startActivity(intent)
Hope this will help to implict in anko
Thanks.I already solved this problem.