[ODK Developers] ODK Collect help with code

Mustafa,

ODK Collect is customizable so all the buttons end up in Swahili.
Unfortunately no one has performed the translation yet. Here is the
file that would contain the translations.
http://code.google.com/p/opendatakit/source/browse/res/values-sw/strings.xml?repo=collect

The Collect exposes an intent
"org.odk.collect.android.activities.FormEntryActivity" to launch a
blank form filling sessions.

Here is some example code in ODK Tables that calls the intent:
http://code.google.com/p/opendatakit/source/browse/src/org/opendatakit/tables/activities/Controller.java?repo=tables#390

I have filed an issue to have Collect's intents documented:
http://code.google.com/p/opendatakit/issues/detail?id=625

Unfortunately the ODK core team does not have the resources to provide
in-depth help on all topics. We do our best to answer questions on the
email lists. If you feel you need more assistance there is a help for
hire page of people who are looking for ODK projects.

Waylon

··· On Wed, Jul 4, 2012 at 12:19 AM, wrote: > Hello. I am using ODK for collecting survey data using locals in Tanzania, E. Africa. We are a social enterprise dealing in Solar light, water filtration, irrigation, other lifestyle improving items for rural areas. > > However, since we are going to be recruiting locally, we need to make the collection software alot more user friendly and in Swahili. i.e. 5 buttons, Add contact (ODK form), start survey topic 1, start survey topic 2, download new forms, and upload data. > > Since I am not a programmer, I decided to use the MIT app-inventor. Can someone help me with the details and parameters of the android intents (Activitystarter) to launch the ODK form and its subsystems? Things like Action, ActivityClass, ActivityPackage, DataType, DataUri, ExtraKey, ExtraValue, ResultName) > > Thanks, Mustafa

I have worked with ODK customization and Swahili being my national
language, feel that I can help with the translation :slight_smile:

··· On Friday, 6 July 2012 00:49:02 UTC+3, Waylon wrote: > > Mustafa, > > ODK Collect is customizable so all the buttons end up in Swahili. > Unfortunately no one has performed the translation yet. Here is the > file that would contain the translations. > > http://code.google.com/p/opendatakit/source/browse/res/values-sw/strings.xml?repo=collect > > The Collect exposes an intent > "org.odk.collect.android.activities.FormEntryActivity" to launch a > blank form filling sessions. > > Here is some example code in ODK Tables that calls the intent: > > http://code.google.com/p/opendatakit/source/browse/src/org/opendatakit/tables/activities/Controller.java?repo=tables#390 > > I have filed an issue to have Collect's intents documented: > http://code.google.com/p/opendatakit/issues/detail?id=625 > > Unfortunately the ODK core team does not have the resources to provide > in-depth help on all topics. We do our best to answer questions on the > email lists. If you feel you need more assistance there is a help for > hire page of people who are looking for ODK projects. > http://opendatakit.org/help/help-for-hire/ > > Waylon > > On Wed, Jul 4, 2012 at 12:19 AM, wrote: > > Hello. I am using ODK for collecting survey data using locals in > Tanzania, E. Africa. We are a social enterprise dealing in Solar light, > water filtration, irrigation, other lifestyle improving items for rural > areas. > > > > However, since we are going to be recruiting locally, we need to make > the collection software alot more user friendly and in Swahili. i.e. 5 > buttons, Add contact (ODK form), start survey topic 1, start survey topic > 2, download new forms, and upload data. > > > > Since I am not a programmer, I decided to use the MIT app-inventor. Can > someone help me with the details and parameters of the android intents > (Activitystarter) to launch the ODK form and its subsystems? Things like > Action, ActivityClass, ActivityPackage, DataType, DataUri, ExtraKey, > ExtraValue, ResultName) > > > > Thanks, Mustafa >

Thank Waylon,

From your example I can extrapolate the rest of the intents from the AndroidManifest.xml file of the collect repo.

What I really would like is one example mapping the ActivityStarter fields to the Java/Android intent inputs. This way I know data I am passing on. I can guess/experiment with the other intents to get everything working.
For Example:
Action = android.intent.action.VIEW
ActivityClass = org.odk.collect.android
ActivityPackage = org.odk.collect.android.activities.FormEntryActivity
DataType = ?
DataUri = /sdcard/odk/forms/new form.xml
ExtraKey = ?
ExtraValue = ?
ResultName = ?

Will be testing variations in the meantime to see if I can bruteforce it to work =D

··· On Friday, July 6, 2012 12:49:02 AM UTC+3, Waylon wrote: > Mustafa, > > ODK Collect is customizable so all the buttons end up in Swahili. > Unfortunately no one has performed the translation yet. Here is the > file that would contain the translations. > http://code.google.com/p/opendatakit/source/browse/res/values-sw/strings.xml?repo=collect > > The Collect exposes an intent > "org.odk.collect.android.activities.FormEntryActivity" to launch a > blank form filling sessions. > > Here is some example code in ODK Tables that calls the intent: > http://code.google.com/p/opendatakit/source/browse/src/org/opendatakit/tables/activities/Controller.java?repo=tables#390 > > I have filed an issue to have Collect's intents documented: > http://code.google.com/p/opendatakit/issues/detail?id=625 > > Unfortunately the ODK core team does not have the resources to provide > in-depth help on all topics. We do our best to answer questions on the > email lists. If you feel you need more assistance there is a help for > hire page of people who are looking for ODK projects. > http://opendatakit.org/help/help-for-hire/ > > Waylon > > On Wed, Jul 4, 2012 at 12:19 AM, wrote: > > Hello. I am using ODK for collecting survey data using locals in Tanzania, E. Africa. We are a social enterprise dealing in Solar light, water filtration, irrigation, other lifestyle improving items for rural areas. > > > > However, since we are going to be recruiting locally, we need to make the collection software alot more user friendly and in Swahili. i.e. 5 buttons, Add contact (ODK form), start survey topic 1, start survey topic 2, download new forms, and upload data. > > > > Since I am not a programmer, I decided to use the MIT app-inventor. Can someone help me with the details and parameters of the android intents (Activitystarter) to launch the ODK form and its subsystems? Things like Action, ActivityClass, ActivityPackage, DataType, DataUri, ExtraKey, ExtraValue, ResultName) > > > > Thanks, Mustafa

On Friday, July 6, 2012 12:49:02 AM UTC+3, Waylon wrote:

Mustafa,

ODK Collect is customizable so all the buttons end up in Swahili.
Unfortunately no one has performed the translation yet. Here is the
file that would contain the translations.
http://code.google.com/p/opendatakit/source/browse/res/values-sw/strings.xml?repo=collect

The Collect exposes an intent
"org.odk.collect.android.activities.FormEntryActivity" to launch a
blank form filling sessions.

Here is some example code in ODK Tables that calls the intent:
http://code.google.com/p/opendatakit/source/browse/src/org/opendatakit/tables/activities/Controller.java?repo=tables#390

I have filed an issue to have Collect's intents documented:
http://code.google.com/p/opendatakit/issues/detail?id=625

Unfortunately the ODK core team does not have the resources to provide
in-depth help on all topics. We do our best to answer questions on the
email lists. If you feel you need more assistance there is a help for
hire page of people who are looking for ODK projects.
http://opendatakit.org/help/help-for-hire/

Waylon

On Wed, Jul 4, 2012 at 12:19 AM, info@tgharusha.com wrote:

Hello. I am using ODK for collecting survey data using locals in Tanzania, E. Africa. We are a social enterprise dealing in Solar light, water filtration, irrigation, other lifestyle improving items for rural areas.

However, since we are going to be recruiting locally, we need to make the collection software alot more user friendly and in Swahili. i.e. 5 buttons, Add contact (ODK form), start survey topic 1, start survey topic 2, download new forms, and upload data.

Since I am not a programmer, I decided to use the MIT app-inventor. Can someone help me with the details and parameters of the android intents (Activitystarter) to launch the ODK form and its subsystems? Things like Action, ActivityClass, ActivityPackage, DataType, DataUri, ExtraKey, ExtraValue, ResultName)

Thanks, Mustafa

The above example doesn't work, Error 601: No corresponding activity found.

This is a question for the app-inventor folks. Given the Java code showing
how we expect the intent to be invoked, they should be able to tell you
what you need to do.

··· On Fri, Jul 6, 2012 at 4:47 AM, Mustafa Pirbhai wrote:

The above example doesn't work, Error 601: No corresponding activity found.

--
Mitch Sundt
Software Engineer
University of Washington
mitchellsundt@gmail.com