我正在尝试将图像从 url 加载到 xamarin 表单应用程序中的图像视图。但我遇到了一个错误,我没有得到修复。
我正在尝试加载图像,如下所示:
ImageService.Instance
.LoadFile(imageUrl)
.LoadingPlaceholder("user.png")
.Into(btn_profile_pic)
.Source(btn_profile_pic);
我曾尝试仅使用 Into 也仅使用 Source,但出现以下错误:
String does not contain a definition for Into and no extension method 'Into' accepting a first argument of type during could be found
如果我尝试使用 Source,我会收到以下错误:
Non Invocable member TaskParameter.Source cannot be used like a method
btw_profile_pic 是一个图像小部件,我想将图像从 url 加载到图像小部件中。