如何从Windows Azure加载JSON数据 [英] How Load JSON Data from Windows Azure
问题描述
我在Windows 8中有一个从Windows Azure读取JSON的应用程序.我正在制作Windows Phone应用程序,但我想读取相同的JSON.相同的过程不起作用,因为它们具有不同的API.我看了一些例子,然后告诉我
如何在Windows Phone中读取JSON本地模式. (公共异步System.Threading.Tasks.Task LoadLocalDataAsync())
Windows 8引入了Windows.Data.Json命名空间来处理JSON格式的数据. Windows Phone 8平台上不存在此名称空间. Windows Phone 8使用DataContractJsonSerializer,我不知道该怎么做.
如何从Windows Azure读取JSON?
谢谢
I have an application in Windows 8 that reads a JSON from Windows Azure. I'm making a Windows Phone application and I want to read the same JSON. The same procedure does not work because they have different API. I've looked at examples and just tell me
how to read a JSON local mode in Windows Phone. (public async System.Threading.Tasks.Task LoadLocalDataAsync())
Windows 8 introduces the Windows.Data.Json namespace to handle data in the JSON format. This namespace does not exist on the Windows Phone 8 platform. Windows Phone 8 uses DataContractJsonSerializer and I don't know how do the same with this one.
How I can read a JSON from Windows Azure?
Thank You
推荐答案
这是将json读取到应用程序中的一种简便方法……这适用于所有JSON REST Feed,而不仅仅是Azure.
Here is an easy way to read json into your application... this goes for any JSON REST Feed, not just Azure.
我创建了一个有关如何执行此操作的帖子...您可以在这里找到它:
I have create a post on how to do this... you can find it here :
http://thesociablegeek.com/windows-phone-2/wp7-rest-the-easy-way/
http://thesociablegeek.com/windows-phone-2/wp7-rest-the-easy-way/
您还可以使用RestSharp http://restsharp.org/
you can also use RestSharp http://restsharp.org/
如果您在使用这两种方法时都遇到麻烦,请告诉我.我可以进一步提供帮助.
If you have trouble with either of these methods, let me know. I can help further.
Daniel
这篇关于如何从Windows Azure加载JSON数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!