1

I have this code:

val myWebView: WebView = findViewById(R.id.webview) myWebView.settings.javaScriptEnabled = true; myWebView.webViewClient = WebViewClient() myWebView.loadUrl("https://example.org/login") 

I want to change activity when login complete. How can i do it in Kotlin?

4

1 Answer 1

0
 override fun doUpdateVisitedHistory(view: WebView, url: String, isReload: Boolean) { if (myWebView.url != "https://www.kryptex.org/login"){ val intent = Intent(this, NextActivity::class.java) startActivity(intent) } } 
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.