I want to set cookies in a webView inside my app dynamically via the code for a particular user using the app. How can I achieve this? Please help
Also, If the above is not possible is there a way in which I can pass cookie information as headers?
For Windows Phone 7 I used to pass the cookie info as headers while WebBrowser.Navigate function. But I don't know if that can be replicated for a WebView in Windows 8. I am really stuck here :(
- Proposed as answer by Jesse JiangMicrosoft community contributor Wednesday, November 21, 2012 6:30 AM
- Edited by Can BilginMVP Wednesday, November 21, 2012 7:56 AM
- Marked as answer by Jesse JiangMicrosoft community contributor Monday, November 26, 2012 9:19 AM
- Unmarked as answer by Milan Aggarwal Monday, January 14, 2013 9:38 AM
I am trying to do the exact same thing and setting the auth cookie with an InvokeScriptAsync didn't work for me either. In my case, I am successfully pulling html from a column in a SharePoint Online list and displaying it in a webview control. Unfortunatley, the html has image tags that reference back to assets in SPO, and the image fails to load because the WebView doesn't pass the Auth token back with the request for the image.
A solution was posted here:
Got a bug or feature request? Tell me about it at http://connect.microsoft.com. This posting is provided "AS IS" with no warranties, and confers no rights.