How to get html page content on button click in Xamarin.Forms?

developer007developer007 ✭✭Member ✭✭

Hi,
I am creating an application in that it gets data from the web view that opens from the page and when the user enters data and then save into that then it saves data into the database using c#.

I have to try to make a local Html webpage and on click of button try to get the value of Html page content but when I try with that I am not able to do that.

I also try with the hosted web URL but can't do that.

I am using .Net standard 2.0.3

Can anyone look into this and suggest to me what should I to do to achieve that?

Answers

  • lbk3lbk3 ✭✭ Member ✭✭

    Can you be a bit more descriptive on what you mean by "content"? Do you want the URL? A specific string?

  • developer007developer007 ✭✭ Member ✭✭

    @lbk3 said:
    Can you be a bit more descriptive on what you mean by "content"? Do you want the URL? A specific string?

    Thanks for the reply.
    In a Webview user enter text with bold and italic and other functionalities like reach textbox when user click on submit it save into local database(SQLite) with the same when the user enters on time of add.
    Also, the user has the functionality of edit text with the same functionality with pre-loaded old text.

  • ColeXColeX Xamurai Member, Xamarin Team Xamurai
    edited August 12

    Check Implementing a HybridWebView , it tells you how to allow C# code to be invoked from JavaScript with custom webview .

    The sample it provides is similar to your case ,you just need to replace the part of showing alert with saving data into local database .

Sign In or Register to comment.