Convert an send a picture via bluetooth

Hi,
i’m trying to convert a picture that i pick with “image picker” to a string that after i’ll send via bluetooth.
i use the file2String extension but it doesn’t work.
image
the picture works well, when i select an image i can see it in the app,
label1: "/storage/emulated/0/DCIM/Camera/pictureName.jpg
then the app crashes.

where am i wrong?

Thanks

Convert it to base64

1 Like

like this?

it works with a small picture but if i select a large picture or a gif the app will crash

EDIT
now the extension works but i have another problem (i changed the title for clarity ).
i can convert the picture (approximatly 5mb) to a string, i send it via bluetooth but in the server side i receive only a part, some kb.

is it possible to send a 5mb picture or it is to heavy?