Accessing the methods of a preprocessor name dataset in Progress 4GL

Status
Not open for further replies.
U

user3597088

Guest
I'm trying to access the methods of a dataset in Progress, where the dataset is defined as a preprocessor item. I'm just learning 4GL... maybe this isn't even possible? Here is the scenario in code:

/*My Procedure*/
{Receipt/Receipt_ds.i}

def var hReceipt as handle no-undo.
def var hDataSet as handle no-undo.

run Receipt/Receipt.p persistent set hReceipt.
run GetData in hReceipt ({&input-output_dataset_ReceiptDataSet}).
/* do some stuff */

/* get the handle to the dataset??? Obvious syntax issue here. */
hDataSet = DATASET {&input-output_dataset_ReceiptDataSet}:HANDLE.

/* Empty the DataSet (this is what I want to do)*/
hDataSet:EMPTY-DATASET().


/*Receipt/Recipt_ds.i*/
define dataset ReceiptDataSet for
ttRcvHead,
ttRcvDtl,
data-relation for ttRcvHead, ttRcvDtl relation-fields(
stuff, stuff
).
&global-define input-output_dataset_ReceiptDataSet input-output dataset ReceiptDataSet


Clearly my code does not have the correct syntax as mentioned in my comment. Does anyone know what the right way of doing this would be?

Continue reading...
 
Status
Not open for further replies.
Top