'Resize image
Dim tempbitmap As Bitmap
'tempbitmap =ReziseImage(Dir,FileName,1600)<<<<<<<<<<<<COMENT THIS LINE
tempbitmap=LoadBitmap(Dir,FileName)<<<<<<<<<<<<<<<<<ADD THIS LINE
'Save reduced image
Dim out As OutputStream
out = File.OpenOutput(File.DirInternal, FileName , False)
tempbitmap.writeToStream(out, 70, "JPEG")<<<<<<<<<<<<<<<MODIFY THE QUALITY VALUE (70 I TESTED THAT ITS OK)
out.Close
'Call sub to upload photo with the rest of information (date, name, etc..)