执行时使用来自异步任务的对象 [英] Use objects from async task while executing

查看:55
本文介绍了执行时使用来自异步任务的对象的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hello

我想知道在任务完成之前是否可以使用异步任务中的对象。

I would like to know if the objects from an async task can be used before the task is completed.

我正在使用以下方式加载联系人:

I am loading the contacts using:

问题是它需要大约2秒才能完成,我需要尽快处理联系对象。

the problem is that it takes about 2 seconds to finish and i need to deal with the contact objects as soon as possible.

什么可以解决?

谢谢

推荐答案

您必须等待SearchCompleted事件触发。
You have to wait for the SearchCompleted event to fire.


这篇关于执行时使用来自异步任务的对象的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆