Hello CSPRO community,
Am Seeking for assistance from any one out there to help me fix this issue, asap. I have been working on developing a menu for my application. This menu is supposed to help enumerators do listing of households before the interview. So, when I run the menu option, and from the interviewer main menu, I have the option to 1. List households 2. Interview households 9. logout. Only options 2 and 3 are working . When I choose option 1 then I get 'application load failed'..
I have already written a function for launchHouseholdListing() in global proc global and it compiled successfully
function launchHouseholdListing()
// Launch household Listing questionnaire in data data entry application
string pffFilename = pathname(Application) + "../LBPAS1718APS/Listing.pff";
if setfile(pffFile,pffFilename,create) = 0 then
errmsg("Failed to open file %s", pffFilename);
endif;
filewrite(pffFile,"[Run Information]");
filewrite(pffFile,"Version=CSPro 7.0");
filewrite(pffFile,"AppType=Entry");
filewrite(pffFile,"[DataEntryInit]");
// Use modify mode if the case already exists in the household
// data file, otherwise use add mode.
string mode;
open(Listing_DICT);
if loadcase(Listing_DICT) = 1 then
mode = "modify";
else
mode = "Add";
endif;
close(Listing_DICT);
filewrite(pffFile,"StartMode=%s;%s",mode, CHOOSE_HOUSEHOLD);
filewrite(pffFile,"[Files]");
filewrite(pffFile,"Application=%s" , "../LBPAS1718APS/Listing.ent");
filewrite(pffFile,"InputData=%s","../Data/Listing.csdb");
{
filewrite(pffFile,"[ExternalFiles]");
filewrite(pffFile,"DISTRICTSPERPROVINCE_DICT=" + pathname(Application) + "../Household/Resources/DistrictsPerProvince.dat");
filewrite(pffFile,"DISTRICTS_DICT=" + pathname(Application) + "../Household/Resources/Districts.dat");
filewrite(pffFile,"ENUMERATIONAREAS_DICT=" + pathname(Application) + "../Household/Resources/EnumerationAreas.dat");
filewrite(pffFile,"HOUSEHOLDPOSSESSIONVALUE_DICT=" + pathname(Application) + "../Household/Resources/HouseholdPossessionValues.dat");
}
filewrite(pffFile,"[UserFiles]");
filewrite(pffFile,"TEMPFILE=%s","");
filewrite(pffFile,"[Parameters]");
filewrite(pffFile,"LI_COUNTY=%s", CHOOSE_HOUSEHOLD[1:2]);
filewrite(pffFile,"LI_DISTRICT=%s", CHOOSE_HOUSEHOLD[3:2]);
filewrite(pffFile,"LI_CLAN=%s", CHOOSE_HOUSEHOLD[5:3]);
filewrite(pffFile,"LI_EA=%s", CHOOSE_HOUSEHOLD[8:2]);
filewrite(pffFile,"LI_AREA=%s", CHOOSE_HOUSEHOLD[10:1]);
filewrite(pffFile,"LI_HH=%s", CHOOSE_HOUSEHOLD[11:2]);
close(pffFile);
execpff(filename(pffFile));
//stop(1);
Attached is screen capture of the menu and the application itself.
Application load failed!! Urgent
-
- Posts: 574
- Joined: July 9th, 2012, 11:32 am
- Location: Islamabad, Pakistan
Re: Application load failed!! Urgent
Dear;
The error is in your path.
Please use Listing instead LBPAS1718APS.
string pffFilename = pathname(Application) + "../Listing/Listing.pff";
filewrite(pffFile,"Application=%s" , "../Listing/Listing.ent");
Best.
A.
The error is in your path.
Please use Listing instead LBPAS1718APS.
string pffFilename = pathname(Application) + "../Listing/Listing.pff";
filewrite(pffFile,"Application=%s" , "../Listing/Listing.ent");
Best.
A.
Re: Application load failed!! Urgent
Thanks Arshad,
It is now working and many thanks.
It is now working and many thanks.