Closed bogdan-voitovych closed 6 years ago
This is work for me. Thanks.
var file = new SmbFile("smb://@192.168.1.102/Pictures/start.png");
var readStream = file.GetInputStream();
var memStream = new MemoryStream();
((Stream)readStream).CopyTo(memStream);
ImageSource ProfileImage = ImageSource.FromStream(() => new MemoryStream(memStream.ToArray())); //Conver from chararray to image
Image1.Source = ProfileImage; //xaml name:
This is work for me. Thanks.
var file = new SmbFile("smb://@192.168.1.102/Pictures/start.png");
var readStream = file.GetInputStream();
var memStream = new MemoryStream();
((Stream)readStream).CopyTo(memStream);
ImageSource ProfileImage = ImageSource.FromStream(() => new MemoryStream(memStream.ToArray())); //Conver from chararray to image
Image1.Source = ProfileImage;
//xaml name
How I can load image to button from local folder?