Mdn 0212Dg.Pdf
Total Page:16
File Type:pdf, Size:1020Kb
Simply Stunning. Today’s users expect beautiful apps in every part of their lives, from work to home. Now, with +L],_WYLZZ[VVSZ`V\JHUHWWS`ZVWOPZ[PJH[LK[OLTLZHUKPUJVYWVYH[LLSLNHU[6MÄJLPUZWPYLK controls into your designs. DXv2 delivers the tools you need to inspire and be inspired. +V^USVHK[OLKH`MYLL[YPHS[VL_WLYPLUJL[OLUL_[NLULYH[PVUVMKL]LSVWLY productivity tools at www.DevExpress.com Untitled-14 1 12/9/11 4:18 PM THE MICROSOFT JOURNAL FOR DEVELOPERS FEBRUARY 2012 VOL 27 NO 2 Asynchronous Programming in C++ Using PPL COLUMNS Artur Laksberg ......................................................................... 22 DATA POINTS A Few of My Favorite Building a Massively Scalable Platform Things … in the Entity Framework 4.2 DbContext for Consumer Devices on Windows Azure Julie Lerman, page 6 Bruno Terkaly and Ricardo Villalobos ......................................... 28 FORECAST: CLOUDY Features and Foibles of ASP.NET MVC Model Binding Windows Azure Jess Chadwick .......................................................................... 36 Deployment Domains Joseph Fultz, page 12 Practical Cross-Browser HTML5 Audio and Video TEST RUN John Dyer ................................................................................ 46 Ant Colony Optimization James McCaffrey, page 70 Get Your Windows Phone Applications THE WORKING in the Marketplace Faster PROGRAMMER Cheryl Simmons ....................................................................... 54 Talk to Me: Voice and SMS in the Cloud What’s New in Windows Workfl ow Foundation 4.5 Ted Neward, page 76 Leon Welicki ............................................................................ 60 CLIENT INSIGHT Getting Started with Knockout Creating a NuGet Gallery John Papa, page 80 ................................................................................. Clark Sell 66 TOUCH AND GO Background Audio on Windows Phone 7.5 Charles Petzold, page 84 DON’T GET ME STARTED Ring Around My Neck David Platt, page 88 Write Once, Experience Many check out infragistics.com/jquery NetAdvantage® for jQuery TREE Simplify the look of hierarchical data, while offering the BUSINESS CHARTING experience, design Combine interactive and functionality Outlook style grids with your users will love! rich business charting to deliver a complete portable solution. Infragistics Sales 800 231 8588 • Infragistics Europe Sales +44 (0) 800 298 9055 • Infragistics India +91 80 4151 8042 • @infragistics Copyright 1996-2011 Infragistics, Inc. All rights reserved. Infragistics and NetAdvantage are registered trademarks of Infragistics, Inc. The Infragistics logo is a trademark of Infragistics, Inc. Untitled-5 2 10/12/11 1:24 PM HTML EDITOR Give your users a powerful HTML editing experience by incorporating the COMBO jQuery WYSIWYG The fully featured editing tool. combo box control HIERARCHICAL GRID offers intuitive An expandable data grid auto-suggest, that presents multiple auto-complete and parent-child relationships auto-filtering built in. VIDEO PLAYER is the backbone of your When a user finds data application. what they want to watch, our HTML5 video player adds streaming video right into your own apps. Untitled-5 3 10/12/11 1:24 PM FEBRUARY 2012 VOLUME 27 NUMBER 2 magazine LUCINDA ROWLEY Director KIT GEORGE Editorial Director/[email protected] PATRICK O’NEILL Site Manager MICHAEL DESMOND Editor in Chief/[email protected] DAVID RAMEL Technical Editor SHARON TERDEMAN Features Editor WENDY GONCHAR Managing Editor KATRINA CARRASCO Associate Managing Editor SCOTT SHULTZ Creative Director JOSHUA GOULD Art Director CONTRIBUTING EDITORS Dino Esposito, Joseph Fultz, Kenny Kerr, Julie Lerman, Dr. James McCaffrey, Ted Neward, Charles Petzold, David S. Platt Henry Allain President, Redmond Media Group Matt Morollo Vice President, Publishing Doug Barney Vice President, Editorial Director Michele Imgrund Director, Marketing Tracy Cook Online Marketing Director ADVERTISING SALES: 508-532-1418/[email protected] Matt Morollo VP, Publishing Chris Kourtoglou Regional Sales Manager William Smith National Accounts Director Danna Vedder Microsoft Account Manager Jenny Hernandez-Asandas Director Print Production Serena Barnes Production Coordinator/[email protected] Neal Vitale President & Chief Executive Offi cer Richard Vitale Senior Vice President & Chief Financial Offi cer Michael J. Valenti Executive Vice President Christopher M. Coates Vice President, Finance & Administration Erik A. Lindgren Vice President, Information Technology & Application Development David F. Myers Vice President, Event Operations Jeffrey S. Klein Chairman of the Board MSDN Magazine (ISSN 1528-4859) is published monthly by 1105 Media, Inc., 9201 Oakdale Avenue, Ste. 101, Chatsworth, CA 91311. Periodicals postage paid at Chatsworth, CA 91311-9998, and at additional mailing offi ces. Annual subscription rates payable in US funds are: U.S. $35.00, International $60.00. Annual digital subscription rates payable in U.S. funds are: U.S. $25.00, International $25.00. Single copies/back issues: U.S. $10, all others $12. Send orders with payment to: MSDN Magazine, P.O. Box 3167, Carol Stream, IL 60132, email [email protected] or call (847) 763-9560. POSTMASTER: Send address changes to MSDN Magazine, P.O. Box 2166, Skokie, IL 60076. Canada Publications Mail Agreement No: 40612608. Return Undeliverable Canadian Addresses to Circulation Dept. or XPO Returns: P.O. Box 201, Richmond Hill, ON L4B 4R5, Canada. Printed in the U.S.A. Reproductions in whole or part prohibited except by written permission. Mail requests to “Permissions Editor,” c/o MSDN Magazine, 4 Venture, Suite 150, Irvine, CA 92618. Legal Disclaimer: The information in this magazine has not undergone any formal testing by 1105 Media, Inc. and is distributed without any warranty expressed or implied. Implementation or use of any information contained herein is the reader’s sole responsibility. While the information has been reviewed for accuracy, there is no guarantee that the same or similar results may be achieved in all environments. Technical inaccuracies may result from printing errors and/or new developments in the industry. Corporate Address: 1105 Media, Inc., 9201 Oakdale Ave., Ste 101, Chatsworth, CA 91311, www.1105media.com Media Kits: Direct your Media Kit requests to Matt Morollo, VP Publishing, 508-532-1418 (phone), 508-875-6622 (fax), [email protected] Reprints: For single article reprints (in minimum quantities of 250-500), e-prints, plaques and posters contact: PARS International, Phone: 212-221-9595, E-mail: [email protected], www.magreprints.com/ QuickQuote.asp List Rental: This publication’s subscriber list, as well as other lists from 1105 Media, Inc., is available for rental. For more information, please contact our list manager, Merit Direct. Phone: 914-368-1000; E-mail: [email protected]; Web: www.meritdirect.com/1105 All customer service inquiries should be sent to [email protected] or call 847-763-9560. Printed in the USA Untitled-3 1 1/9/12 12:36 PM EDITOR’S NOTE MICHAEL DESMOND Calling out the Client A month ago in this space, I wrote about an MSDN Magazine Conference. He eventually joined Microsoft to help evangelize the author and columnist—Charles Petzold—who marked his 25th year company’s RIA eff orts. as a contributor to this publication. So it’s appropriate, I suppose, “When I got into Silverlight I saw a great opportunity to work that I dwell now on another valued columnist who left the maga- with patterns, data and client-side RIA technology,” Papa says. “Th e zine aft er more than a decade, only to return to the fold this month. opportunity I had to be the corporate evangelist for Silverlight/ John Papa first began writing for MSDN Magazine back in XAML was awesome. Th ey gave me the freedom to run and try December 1998, and for eight years from 2002 through 2009 new ideas like Silverlight TV, running communities, MIXer parties, authored the popular Data Points column, which continues today open source events, the Silverlight Firestarter and much more.” under the stewardship of Julie Lerman. Papa wrote his last column in February 2009, stepping down when he took on a role with Microsoft as a corporate evangelist for Silverlight and XAML. Now “We need to use the right tool for Papa is back, penning a new column called Client Insight, which focuses on the fast-changing arena of rich client development the right job. A lot has changed technologies and platforms. “Client technology has really changed over the past few years just in the past two years, with XAML, HTML5 and mobile devices,” says Papa, who adds that he hopes to bring together the best parts of XAML and HTML5. but that rule hasn’t.” “I plan on exploring the good, the bad and the challenging aspects of client technologies,” he continues. “Anyone interested in So why the Client Insight column, and why now? writing soft ware for the next generation should enjoy the column For one thing, Papa left Microsoft in November to move back as I plan to cover HTML5, CSS3, JavaScript, patterns, XAML, to his native Florida, where he had lived prior to relocating to mobility, tooling and much more.” the Redmond area in 2009. More to the point, the emergence of For Papa, the new column is a second chance to pursue a passion. JavaScript/HTML5, alongside the evolving Microsoft XAML/ Th e Data Points column got its start in 1998 because he felt at the Silverlight strategy, has turned the client development space on its time that data-related topics were being neglected.