Skip to content

Instantly share code, notes, and snippets.

@kypflug
Created Jun 12, 2015
Embed
What would you like to do?
JsProjectWinRTNamespace(L"Windows.Foundation");
JsProjectWinRTNamespace(L"Windows.Web");
// Get content from an Uri.
JsRunScript(
L"var uri = new Windows.Foundation.Uri(\"http://somedatasource.com\"); " \
L"var httpClient = new Windows.Web.Http.HttpClient();" \
L"httpClient.getStringAsync(uri).done(function () { " \
L" // do something with the string content " \
L"}, onError); " \
L"function onError(reason) { " \
L" // error handling " \
L"}", JS_SOURCE_CONTEXT_NONE, L"", &result);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment