-1

I'm kind of new to Xamarin and I have a simple problem but no idea to how do that.

I have written an app with Xamarin forms. the problem is Here that I want user connect to my website do sth and then come back to the app. I need to change a Boolean in Xamarin to true when the task is done in website.

how I can get this information (just turn a false to true) from web? I have no idea so any help will appreciated.

  • This is a very vague requirement. Is there some user action you can verify that has been done on the web, by calling a REST API? – Jason Aug 08 '21 at 12:09
  • As @Jason said, the requirement is very vague. The is generally no way for a website to notify a specific mobile device of a change. The way to do something like this would be for the mobile app to call the website and retreive changes. You could call the website when the user exits the browser and goes back to the mobile app. – Michal Diviš Aug 09 '21 at 08:35

1 Answers1

0
  1. Determine the name of the function on your JS.
  2. Use webView.EvaluateJavascript("javascript: callJS();", new EvaluateBack()); to get the callback value of the corresponding method. Check this link for more information: How to run a Java Script function and get return in Android?
Wen xu Li
  • 1,698
  • 1
  • 4
  • 7