I need file transfer exchange with remote host and android. lazarus / 43-Android ---------------------------------------------------------------------- Fortuna1 · 2012-09-29 14:38 I need file transfer exchange with remote host and android. Automatically with program Lazarus. Maybe FTP or something else.  What suggestion? ---------------------------------------------------------------------- BigChimp · 2012-09-29 14:54 FTP, good idea, if you don't mind that it's unencrypted. ---------------------------------------------------------------------- Fortuna1 · 2012-09-30 10:41 I try ftp with sysnapse. use ftpsend; Code: [Select]   Result:=   FtpGetFile('192.168.1.111', '2221', 'unit1.pas', 'aaaa','francis','francis'');         Result:=  FtpPutFile('192.168.1.111', '2221', 'unit1.pas', 'unit1.pas','francis','francis'); NonAndroidTest   work ok. AndroidTest with compile say this message: Wrong number of parameters specified for call to "Bind" How to use FPT in Android?? ---------------------------------------------------------------------- Fortuna1 · 2012-09-30 11:46 Instal the last synapse40.zip. http://www.ararat.cz/synapse/files/archive/ compile now not crash. ---------------------------------------------------------------------- BigChimp · 2012-09-30 11:48 Another reason to follow the advice in my signature... ---------------------------------------------------------------------- Fortuna1 · 2012-09-30 15:35 my os window7 65-bit Lazarus-1.1-38674-fpc-2.6.0-20120916-win32 synapse40.zip Android Samsung not III. NonAndroidTest work OK,  FtpPutFile WORK OK. But  FtpGetFile  crashed with except. If not have "try and except" program crashed and stop work. Code: [Select]procedure TForm1.Button5Click(Sender: TObject); var   Result:boolean; begin Result:=FtpPutFile('192.168.1.38', '21', 'tralala.pas', '/mnt/sdcard/Application/unittest.pas','usb','bar');  // FtpPutFile WORK OK.   try Result:=FtpGetFile('192.168.1.38', '21', 'tralala.pas', '/mnt/sdcard/Application/gettest.pas','usb','bar');   except    Memo1.Lines.Add('except get');   end; How to find the error message? I do not know any idea what is wrong? ---------------------------------------------------------------------- Fortuna1 · 2012-09-30 16:51 Code: [Select]    try Result:=FtpGetFile('192.168.1.38', '21', 'tralala.pas', '/mnt/sdcard/Application/gettest.pas','usb','bar');   except     on e:Exception do     Memo1.Lines.Add(e.ClassName +'  '+e.Message);   end; I get message Unable to create file "/mnt/sdcard/Application/gettest.pas". ---------------------------------------------------------------------- Fortuna1 · 2012-09-30 17:32 I try with gettest.pas /sdcard/Application/gettest.pas /tmp/gettest.pas Always the same message. I have no more ideas. ---------------------------------------------------------------------- Fortuna1 · 2012-10-01 07:16 Code: [Select]VAR FFF:TEXTFILE; begin   TRY         ASSIGNFILE(FFF,'/mnt/sdcard/Application/TEST.txt');  /// OK       Rewrite(fff);    // HERE GET  Access denied           writeln(fff,'test test') ;           closefile(FFF);             except   on e:Exception do      BEGIN         Memo1.Lines.Add(e.Message); How change permissions on android folder? or run my aplication as root on android? ---------------------------------------------------------------------- zariq · 2012-10-01 07:51 The permissions go in the androidmanifest.xml file. To allow the program to write a file to the external sd card you would need to put the following permission.     ---------------------------------------------------------------------- Fortuna1 · 2012-10-01 09:33 where found this file? androidmanifest.xml ---------------------------------------------------------------------- BigChimp · 2012-10-01 09:51 Do you have acccess to the internet? Can you try using a search engine? Try searching for androidmanifest.xml permissions how to There must be tons of information on Android out there... asking on a Lazarus forum may give you some helpful answers, but Android specific information is likely to be found on an Android site. ---------------------------------------------------------------------- Fortuna1 · 2012-10-01 10:16 i found  file  C:\lazarus\examples\androidlcl\androidmanifest.xml Wonderful. Now work all. The biggest thank you to all.