FTP Sync

Discussions about CSEntry
adisa
Posts: 3
Joined: September 18th, 2014, 9:28 am

FTP Sync

Post by adisa »

Hello,

I am trying to sync data from android device to ftp server, but it isn't working.
Does anyone tried to sync data using ftp server? :?
Gregory Martin
Posts: 1845
Joined: December 5th, 2011, 11:27 pm
Location: Washington, DC

Re: FTP Sync

Post by Gregory Martin »

I have synced many files between my Android phone and my FTP server. Have you looked at the sync instructions here:

http://www.csprousers.org/help/html/dat ... zation.htm

Remember that you first have to download a .pnc (sync file) to your device, and then you can perform a synchronization.
MrTaco
Posts: 128
Joined: November 18th, 2014, 1:55 am

Re: FTP Sync

Post by MrTaco »

HI, How do i download pnc.file to my device... coz i have been trying to sync ftp with my smartphone?
adisa
Posts: 3
Joined: September 18th, 2014, 9:28 am

Re: FTP Sync

Post by adisa »

You should put .pnc file on ftp server and after you connect your smartphone with the server you should see the .pnc file listed
MrTaco
Posts: 128
Joined: November 18th, 2014, 1:55 am

Re: FTP Sync

Post by MrTaco »

okay thanks will do....
MrTaco
Posts: 128
Joined: November 18th, 2014, 1:55 am

Re: FTP Sync

Post by MrTaco »

So one another thing is it possible to assign each and every user to login, so they could work on their Folder or Batch numbers?

thanks
josh
Posts: 2401
Joined: May 5th, 2014, 12:49 pm
Location: Washington DC

Re: FTP Sync

Post by josh »

Yes it is. You would have to create a separate sync file for each user since the login username is included in the sync file.

Alternatively you could use the same login for all users and include %UID% in the path for the folder that each user syncs to (for example

Code: Select all

ServerPath=/%AppName%/Data/%UID%
). This way each user's data will get written to a different folder on the server based on the username set on the Android device.
arkagwa
Posts: 119
Joined: November 18th, 2014, 5:25 am

Re: FTP Sync

Post by arkagwa »

Dear Josh
everything is working perfect for mein FTP, expect two issues.
1.The data entry allows duplicate questionnaire id (identifier) in mobile form while same app in PC can detect duplicate identifier
2.I have entered 4 cases and iwant to download back the file to Pc but when i download it , the file with my use name is empty. How do i get the data file???

Here is my code in mynsyncftp.pnc file allocated in ftp://ftp.research-eperts.org/CSPROSYNC
[SyncFile]
Version=CSPro 6.0
AppName=UG FORM FTP
[Server]
Type=FTP
Host=ftp://ftp.research-experts.org/
Username=arkagwa
Password=***********
[Sync]
ServerPath=/%AppName%
CreateClientPath=/%AppName%
CreateClientPath=/%AppName%/Data
ClientPath=/%AppName%
Get=*.*

the other two files are located here:
ftp://ftp.research-experts.org/UG FORM FTP/UG FORM.pen
ftp://ftp.research-experts.org/UG FORM FTP/UG FORM.pff
josh
Posts: 2401
Joined: May 5th, 2014, 12:49 pm
Location: Washington DC

Re: FTP Sync

Post by josh »

CSPro should never allow duplicate case identifiers either on the PC or on Android. I would have to see your application code in order to see why this is hapening.

The reason that you are not seeing your data file downloaded from the device is because yor sync specification file is not correct. You are using Get *.* in your sync which downloads from the FTP server to the Android device (the client). To transfer from the Android device to the server you need to use the Put command. Also make sure that you use the CreateServerPath and ServerPath to set the correct directory on the FTP server to upload your data files to and to also use the ClientPath command to point the directory on your Android device that contains the data files.
arkagwa
Posts: 119
Joined: November 18th, 2014, 5:25 am

Re: FTP Sync

Post by arkagwa »

Ooooh could be nice to get a pdf doc or video tutorial for this or give clear commands here and root directory. See attached file
Attachments
UG FORM.rar
CSPro data entry file
(13.31 KiB) Downloaded 528 times
Post Reply