Batch error report for current case

Discussions about CSEntry
Forum rules
New release: CSPro 8.0
Post Reply
davide

Batch error report for current case

Post by davide »

Hello,

I would like to add the following feature to my data entry program:

When a case is finished by the data entry operator, a batch file is run automatically which creates an error report for the current case ONLY (so not all cases in the data file).

Does anyone have an idea what is the most efficient way of doing this? I don't really see yet how I could filter the data file to get the current case.

Thanks,

David Pap
Gregory Martin
Posts: 1777
Joined: December 5th, 2011, 11:27 pm
Location: Washington, DC

Re: Batch error report for current case

Post by Gregory Martin »

The problem with your idea is that CSEntry, the data entry program, locks your data file, meaning that you will not be able to read it from a batch program until you stop data entry while in CSEntry (or close CSEntry completely).

One way to solve your problem is to:

1) Write a menu program that launches CSEntry, where the operator will enter a case. CSEntry will close after the single case is entered.
2) The menu program waits until CSEntry finishes.
3) Then the menu program launches the batch application, specifying the case to operate on using the Parameter attribute in the PFF file.
4) Your batch application only focuses on that case. In the preproc of your questionnaire level you would check if the ID is the one you want to process, and if not it would call the endcase statement to stop processing the case.

See attached for a simplified example of how you might do this. Run menu.pff to start the program.
Attachments
menuEntryBatch.zip
(5.79 KiB) Downloaded 387 times
davide

Re: Batch error report for current case

Post by davide »

Thanks Gregory,
this works perfectly!

David
Post Reply