Exemple #1
0
        public async void ShowTodaysWallapaper(string imageURL)
        {
            byte[] todaysImage = await bingRepo.GetImage(imageURL);

            UIImage bingImage = new UIImage(NSData.FromArray(todaysImage));

            todaysBingWallpaper.Image = bingImage;
        }
Exemple #2
0
        private async void ShowTodaysWallapaper(string imageURL)
        {
            byte[] todaysImage = await bingRepo.GetImage(imageURL);

            File.WriteAllBytes(wallpaperName, todaysImage);
            if (File.Exists(wallpaperName))
            {
                Console.WriteLine("File created successfully");
            }

            Bitmap bitmap = BitmapFactory.DecodeByteArray(todaysImage, 0, todaysImage.Length);

            bingImage.SetImageBitmap(bitmap);
        }