Page 1 of 1
Identifying devices in sync routine. %UID% %DeviceID%
Posted: June 1st, 2015, 9:10 pm
by jbthompson21
Hi Everyone, I'm setting up a syn .PNC file to upload survey data results to dropbox. I've got everything working great but I've found that %UID% returns only the email name on which each tablet is logged in. The problem is that I've got 20 tablets and i have them all logged in under the same google and matched dropbox account for ease. This therefor makes all the %UID%'s the same which when looking doesn't give me a way to quickly tell which tablets and therefore enumerators have their data uploaded. Is there another phrase that I can use? I have tried %DeviceID% but although I thought I reset this, it's just giving me a long predetermined and, I believe unchangeable set of numbers and letters. Is there any way I can use the Device Name here or something else I can set without the hassle of individual email and dropbox accounts on each device?
Thanks!
Re: Identifying devices in sync routine. %UID% %DeviceID%
Posted: June 2nd, 2015, 11:22 am
by josh
The %UID% comes from the gmail address that is used to set up the Android device so if you use the same gmail on all your devices this will not be helpful. It is easy enough to change the gmail address of a device once it has been set up in the settings without resetting the whole and device and doing the setup again.
The %DeviceID% will use the Android ID of the device which is a long and ugly string that is generated by Android when the device is first set up. Is unique for each device and will not change unless you do a factory reset of the device. You cannot change this. If you use the %DeviceID% then you need to maintain a spreadsheet or something that matches the DeviceId with the name of the enumerator.
Re: Identifying devices in sync routine. %UID% %DeviceID%
Posted: June 2nd, 2015, 6:19 pm
by jbthompson21
Great! Thanks for the help! I think i'm just going to redo the gmail accounts, seems to be the easiest way forward.
Re: Identifying devices in sync routine. %UID% %DeviceID%
Posted: September 2nd, 2015, 9:13 am
by Sigma
Is there a way to save UID and DEVICEID into datafile?
Re: Identifying devices in sync routine. %UID% %DeviceID%
Posted: September 2nd, 2015, 9:54 am
by josh
You can access them from logic using the functions getdeviceid() and getusername(). To get them into the data file create alpha variables in your dictionary and assign the return values of those functions to the dictionary variables.
Re: Identifying devices in sync routine. %UID% %DeviceID%
Posted: September 2nd, 2015, 10:50 am
by Sigma
Thanks! That's what I was looking for
