Oh the Lambda option sounds interesting. I've only done a little with this, could someone throw together an example? (something simple) cheers, Stephen
On Mon, Mar 2, 2009 at 7:47 AM, Jordan Knight <[email protected]>wrote: > Pass through user context to the getASync method, which is then available > as e.UserContext on the return call. > > > > Or use the Lambda + Closure method as Miguel suggested. > > > > *From:* [email protected] [mailto: > [email protected]] *On Behalf Of *Philip Beadle > *Sent:* Sunday, 1 March 2009 4:36 PM > *To:* [email protected] > *Subject:* RE: Asynch downloading > > > > Fonts was just an example. I have a situation where Im dynamically loading > xap modules and I needed to know which one was loading so i could load the > right class. Got it sorted by passing the ID through with the Asynch call. > Works a treat. Will be blogging it soon. > > > > Regards, > > *Philip Beadle* > Readify | Principal Consultant > Microsoft MVP - ASP/ASP.NET, MCAD, MCT > > Suite 408 LifeLabs Building | 198 Harbour Esplanade | Docklands | VIC 3008 > | Australia > M: +61 417 301 024 | E: [email protected] | C: > [email protected] | W: www.readify.net > > [image: MIS Email Signature > Banner]<http://readify.net/about-readify/press/readify-makes-2008-mis-strategic-100-list/> > > > > *From:* [email protected] [mailto: > [email protected]] *On Behalf Of *Stephen Price > *Sent:* Sunday, 1 March 2009 4:34 PM > *To:* [email protected] > *Subject:* Re: Asynch downloading > > > > What's in your fontDownloader_OpenReadCompleted method? Why do you need to > know which one it is? Your font would be the e.Results so you'd load the > font downloaded into your resources? > > (I've not downloaded fonts before but am interested in this for myself for > downloading "modules" (more xap files) for an app.) > > cheers, > > Stephen > > > > On Sun, Mar 1, 2009 at 10:57 AM, Philip Beadle <[email protected]> > wrote: > > Lets say I have some code that downloads 5 fonts > > > > *foreach* (*var* font *in* fonts) > > { > > *var* fontDownloader = *new* WebClient(); > > fontDownloaderOpenReadCompleted += *this*. > fontDownloader_OpenReadCompleted; > > fontDownloaderOpenReadAsync(*new* Uri(path, UriKind. > Absolute)); > > } > > > > How do I work out which asynch call has finished when the Completed event > runs? I tried adding to the Headers but its busted in SL 2. Any ideas? > > > > Regards, > > *Philip Beadle* > Readify | Principal Consultant > Microsoft MVP - ASP/ASP.NET, MCAD, MCT > > [image: cid:[email protected]] > > Suite 408 LifeLabs Building | 198 Harbour Esplanade | Docklands | VIC 3008 > | Australia > M: +61 417 301 024 | E: [email protected] | C: > [email protected] | W: www.readify.net > ------------------------------ > > The content of this e-mail, including any attachments is a confidential > communication between Readify Pty Ltd and the intended addressee and is for > the sole use of that intended addressee. If you are not the intended > addressee, any use, interference with, disclosure or copying of this > material is unauthorized and prohibited. If you have received this e-mail in > error please contact the sender immediately and then delete the message and > any attachment(s). > > *P** **Please consider your environmental responsibility before printing > this e-mail* > > * * > > [image: MIS Email Signature > Banner]<http://readify.net/about-readify/press/readify-makes-2008-mis-strategic-100-list/> > > > ------------------------------ > > Support procedure: https://www.codify.com/lists/support > List address: [email protected] > Subscribe: [email protected] > Unsubscribe: [email protected] > List FAQ: http://www.codify.com/lists/ozsilverlight > Other lists you might want to join: http://www.codify.com/lists > > > ------------------------------ > > Support procedure: https://www.codify.com/lists/support > List address: [email protected] > Subscribe: [email protected] > Unsubscribe: [email protected] > List FAQ: http://www.codify.com/lists/ozsilverlight > Other lists you might want to join: http://www.codify.com/lists > ------------------------------ > > Support procedure: https://www.codify.com/lists/support > List address: [email protected] > Subscribe: [email protected] > Unsubscribe: [email protected] > List FAQ: http://www.codify.com/lists/ozsilverlight > Other lists you might want to join: http://www.codify.com/lists > > No virus found in this incoming message. > Checked by AVG - www.avg.com > Version: 8.0.237 / Virus Database: 270.11.5/1979 - Release Date: 03/01/09 > 17:46:00 > ------------------------------ > Support procedure: https://www.codify.com/lists/support > List address: [email protected] > Subscribe: [email protected] > Unsubscribe: [email protected] > List FAQ: http://www.codify.com/lists/ozsilverlight > Other lists you might want to join: http://www.codify.com/lists > -------------------------------------------------------------------------------- Support procedure: https://www.codify.com/lists/support List address: [email protected] Subscribe: [email protected] Unsubscribe: [email protected] List FAQ: http://www.codify.com/lists/ozsilverlight Other lists you might want to join: http://www.codify.com/lists
<<image001.jpg>>
<<image002.gif>>
