轉載自:http://www.cnblogs.com/sun8134/archive/2011/09/19/2181030.html
前幾天看園子有篇文章介紹Visual Studio Async
覺得不錯想試試效果,上MS網站下載安裝封裝下
地址:http://www.microsoft.com/download/en/details.aspx?id=9983
(可以在wp7上用的哦)
Overview
The original Async CTP from PDC 10 brought asynchronous programming to C# and Visual Basic in Visual Studio 2010. This refresh introduces the following:
- Compatible with Visual Studio 2010 SP1, which is now required.
- Compatible with non-English installations of Visual Studio and with Visual Studio Express.
- Enables asynchronous development for Windows Phone 7.
- Includes various bug-fixes and changes, detailed in the Readme and documentation.
- Includes a new EULA for production use. Note - This license does not constitute encouragement for you to use the CTP for your production code. The CTP remains an unsupported and use-at-your-own-risk Technology Preview. However, we’ve received many requests from developers to use the CTP for production code, and so have changed the license to allow that.
下載安裝
安裝完成後,杯具了…
“我的文件”裡死活找不到傳說中的“Microsoft Visual Studio Async CTP”檔案夾…
上MSDN論壇,發現多人也有這個情況,找到篇解決方案:
http://social.msdn.microsoft.com/Forums/en-US/async/thread/e63a036d-f79d-4904-8e88-97d4dd152cb1
是因為裝了KB2565057
果斷卸載,結果依然失敗...
看上面那篇的分析:
運行:msiexec /p VS10-KB0000001.msp SHORTFILENAMES=TRUE /qb /L* c:\Temp\log.txt
查看日誌:
MSI (s) (B0:48) [22:20:12:635]: Final Patch Application Order:
MSI (s) (B0:48) [22:20:12:635]: {FC8EA2A2-65A3-366E-A687-5B63943A800F} -
MSI (s) (B0:48) [22:20:12:635]: {FD1050C2-7614-3245-83F1-6B0BE4769064} -
MSI (s) (B0:48) [22:20:12:635]: Other Patches:
MSI (s) (B0:48) [22:20:12:635]: Superseded: {50BE1560-55E5-31CB-AC52-8403B409E46C} - C:\cc78c6b4d0885ab3cd39e29163\VS10-KB0000001.msp
MSI (s) (B0:48) [22:20:12:635]: Superseded: {11195581-0A34-371D-9FB5-F07DE684FDE6} -
……
應該還是有補丁不相容
重裝下KB2565057 (200多M),發現同時vs的其他幾個補丁的更新日期也變了
把這幾個統統卸載
再次運行命令列,查看日誌:
MSI (s) (B8:F8) [21:48:36:475]: Final Patch Application Order:
MSI (s) (B8:F8) [21:48:36:475]: {FC8EA2A2-65A3-366E-A687-5B63943A800F} -
MSI (s) (B8:F8) [21:48:36:475]: {11195581-0A34-371D-9FB5-F07DE684FDE6} -
MSI (s) (B8:F8) [21:48:36:475]: {25961B77-62ED-3599-8618-3A0304110026} -
MSI (s) (B8:F8) [21:48:36:475]: {296218F5-C5A1-3CFE-B3A9-4EF40F5475B4} -
MSI (s) (B8:F8) [21:48:36:475]: {4733D286-44DF-3445-BF68-CBEB4AF97622} -
MSI (s) (B8:F8) [21:48:36:475]: {50BE1560-55E5-31CB-AC52-8403B409E46C} - F:\Xunlei\Async-CTP1\VS10-KB0000001.msp
MSI (s) (B8:F8) [21:48:36:475]: {A1339082-2C37-3126-AE03-9C3E10AA239B} -
現在在裝就沒有問題了
安裝完成後可以在更新裡看到
更多關於Visual Studio Async可以看看:
http://www.abhisheksur.com/2011/04/async-support-for-silverlight-and-wp7.html
安裝失敗的兄弟們可以考慮把那幾個補丁挨個卸載試試
(可能不用全卸載,沒卸載完用命令列試試把…)