Save data with pff

Discussions about creating CAPI applications to run on Android devices
Post Reply
chandi
Posts: 9
Joined: August 12th, 2023, 3:31 am

Save data with pff

Post by chandi »

Hi,
I am manipulating "pff" file and entry Ids using external program. in some cases I can pass all required case values to pff so no need to open data entry, at that point can I save data file without literally opening csentry application. My scope it to feed all data to data file and minimize user activities on data entry whenever, just for few points available such as no respondent etc.
Gregory Martin
Posts: 1796
Joined: December 5th, 2011, 11:27 pm
Location: Washington, DC

Re: Save data with pff

Post by Gregory Martin »

Are you generating the PFF from another CSPro application? If so, and you don't need any input from the user, you can simply construct the case in logic, with the data file's dictionary attached as an external dictionary, and then save the data using writecase:

https://www.csprousers.org/help/CSPro/w ... ction.html

Alternatively, if you still need to open the data entry application, you can use logic, or the values in the PFF, to fill in the appropriate values, and then use endlevel in logic to save the case:

https://www.csprousers.org/help/CSPro/e ... ement.html
chandi
Posts: 9
Joined: August 12th, 2023, 3:31 am

Re: Save data with pff

Post by chandi »

Thanks Greg, It seems I can use endlevel, but at that point can I avoid asking "Accept this case => yes/no" prompt,
I am sending ID fields from android app via intent to CsEntry, sometime I can close case based on IDs Value itself, but it should reflect in final datafile I am stuck in that point as in CsEntry in such cases user does not need to enter anything. So I need to finish data entry from android app itself.
Gregory Martin
Posts: 1796
Joined: December 5th, 2011, 11:27 pm
Location: Washington, DC

Re: Save data with pff

Post by Gregory Martin »

You can turn off that prompt here: https://www.csprousers.org/help/CSPro/c ... tions.html

Uncheck "Confirm end-of-case." I usually do that on most projects, and if I want a confirmation, I add it as the last field on my form.
chandi
Posts: 9
Joined: August 12th, 2023, 3:31 am

Re: Save data with pff

Post by chandi »

Thanks that helps to solve my issue
chandi
Posts: 9
Joined: August 12th, 2023, 3:31 am

Re: Save data with pff

Post by chandi »

I tried this method but I get massage "Warning 1026" "All of the ID fields were not filled, please reenter" I just can save and case is correctly saved. Is there a way to avoid showing this massage too.
If I let user to go through all ID fields (as I am passing ids form intent IDS are filled already, so user just need to click next button") that massage not appear. but I do not want that behavior so I do not have ID form and use logic to end level based on condition inside preproc of the Form.
sherrell
Posts: 397
Joined: April 2nd, 2014, 9:16 pm
Location: Washington, DC

Re: Save data with pff

Post by sherrell »

The user doesn't have to manually acknowledge all the ID fields, you can just prefill them as you're doing and either set the fields to protected (via field property) or add "noinput" to the preproc. But you have to get through the IDs at a minimum before CSPro will allow a case to be saved

Sherrell
Post Reply