Skip to Content
0
Former Member
Dec 20, 2007 at 05:11 PM

JCO Table as import prameter

846 Views

Im just trying to insert some data to the JCO.table ,

// Get table parameters

JCO.ParameterList parameters = function.getTableParameterList();

// Post Event Header info to SAP

JCO.Table docTable = parameters.getTable("DOCTABLE");

int k = getMultipleDocsForm.getDocs().size();

System.out.println("k Size -


>" + k);

// TODO Refractor hard codings.

for(int i=1;i<=k;i++){

//docTable.appendRow()

//docTable.setRow( docTable.getRow() + 1);

//docTable.insertRow(i);

docTable.setValue("","MANDT");

docTable.setValue("1231232","DOKAR");

docTable.setValue("A","DOKNR");

docTable.setValue("0","DOKVR");

docTable.setValue("000","DOKTL");

docTable.insertRow(i);

}

// Call the remote system

System.out.println("Before Executing the SAP");

client.execute(function);

System.out.println("After Executing the SAP");

But it is not getting inserted .

Im new to JCO , can any one help me in this ?