We have our own application that uses Crystal Reports as the reporting tool. We are using Crystal Reports 10 with Java 1.5 for our web application with an Oracle database.
I am trying to create a formula to call a Java function from our application. The steps I'm trying to do are as follows:
Each entity in the database has a jurisdiction it was created in. This formula is to retrieve the original state of formation (jurisidiction). There are 3 parts to complete the process.
Formula 1 calls a function within our application to create the jurisdiction list for all entities:
Shared stringVar array jurisFormationList;
jurisFormationList := getJurisdictionInfoList({?$DATABASEID$})
Formula 2 selects the one entity we are looking for from the list created in Formula 1 and executes the formula TEST:
Shared stringVar inEid;
inEid := CStr({ENTITY.ENTITY_EID},0,"");
{@test};
Formula 3 (Test) selects and displays the jurisdiction for the selected entity:
Shared stringVar array jurisFormationList;
Shared stringVar inEid;
Local stringVar jurisFormation := "";
Local stringVar item;
Local numberVar i;
Local numberVar listLength := Count(jurisFormationList);
for i := 1 to listLength do
(
item := jurisFormationList;
Local numberVar pos = InStr(item, "~");
Local stringVar listEid = Left(item,pos-1);
if inEid = listEid then
jurisFormation := Right(item,pos);
);
jurisFormation
Any suggestions?
Rae
I am trying to create a formula to call a Java function from our application. The steps I'm trying to do are as follows:
Each entity in the database has a jurisdiction it was created in. This formula is to retrieve the original state of formation (jurisidiction). There are 3 parts to complete the process.
Formula 1 calls a function within our application to create the jurisdiction list for all entities:
Shared stringVar array jurisFormationList;
jurisFormationList := getJurisdictionInfoList({?$DATABASEID$})
Formula 2 selects the one entity we are looking for from the list created in Formula 1 and executes the formula TEST:
Shared stringVar inEid;
inEid := CStr({ENTITY.ENTITY_EID},0,"");
{@test};
Formula 3 (Test) selects and displays the jurisdiction for the selected entity:
Shared stringVar array jurisFormationList;
Shared stringVar inEid;
Local stringVar jurisFormation := "";
Local stringVar item;
Local numberVar i;
Local numberVar listLength := Count(jurisFormationList);
for i := 1 to listLength do
(
item := jurisFormationList;
Local numberVar pos = InStr(item, "~");
Local stringVar listEid = Left(item,pos-1);
if inEid = listEid then
jurisFormation := Right(item,pos);
);
jurisFormation
Any suggestions?
Rae