how to convert a Bitmap to a base64 string c# xamarin universal
using(var stream = new MemoryStream())
{
yourBitmap.Compress(Bitmap.CompressFormat.Png,0, stream);
var bytes = stream.ToArray();
var str = Convert.ToBase64String(bytes);
}
how to convert a Bitmap to a base64 string c# xamarin universal
using(var stream = new MemoryStream())
{
yourBitmap.Compress(Bitmap.CompressFormat.Png,0, stream);
var bytes = stream.ToArray();
var str = Convert.ToBase64String(bytes);
}
bitmap to string android xamarin
Bitmap bitmap = BitmapFactory.DecodeResource(Resources, Resource.Drawable.ace1);
MemoryStream stream = new MemoryStream();
bitmap.Compress(Bitmap.CompressFormat.Jpeg, 100, stream);
byte[] ba = stream.ToArray();
string bal = Base64.EncodeToString(ba, Base64.Default);
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us