cancel
Showing results for 
Search instead for 
Did you mean: 

How to set Serial No column in a table

udaykumar_kanike
Active Contributor
0 Kudos

Hi All,

I want to create a SNo. column . With RFC i dint get this column and I have to create this additional column. Please someone help me with code.

Thanks

Uday

Edited by: Uday Kumar Kanike on Jan 13, 2012 12:02 PM

Accepted Solutions (0)

Answers (1)

Answers (1)

p330068
Active Contributor
0 Kudos

Dear Uday,

Create the custom context node and attributes (for populating rfc column data). also you can create extra attribute for Serial No. when you populating data from rfc, add the number in serial no.

like:-


wdContext.node<NODE>().invalidate();
I<NODE>Element ele = null;
for(int i=0; i<wdContext.node<RFC OUTPUT NODE>().size(); i++)
{
      ele = wdContext.create <NODE>Element();
      ele.setSerialNo(i OR i+1);
      //for other attribute
      ele.set<XYZ>(wdContext.node<RFC OUTPUT NODE>().get<RFC OUTPUT NODE>ElementAt(i).get<XYZ>());
      wdContext.node<NODE>().addElement(ele);
}

Hope it will helps

Best Regards

Arun Jaiswal

udaykumar_kanike
Active Contributor
0 Kudos

Hi Arun,

where is this coming from. If you are setting the value to already defined attribute, that is not the case in my scenario. ele.setSerialNo()

I need to create an attribute dynamically. will I be able to do so, with your statements.

Regards

uday