简体   繁体   中英

How to compress response in Webservices in C#?

I am want to compress the response of a webmethod call. This compressed data should be decompressed by different mobile platform like iPhone, Android, Windows Phone 7 and Blackberry. I have checked different solution but did not find any proper solution. Actually we have a webmethod which gives data of around 20,000 records (which is in size around 2 MB). And we would like to to compress data to transfer over HTTP.

Can anyone help me out?

由于您可能在IIS中托管此功能,因此您应该能够启用GZIP压缩。

Have you tried using GZip? take a look at the following technet guide: http://technet.microsoft.com/en-us/library/cc730629(v=ws.10).aspx

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM