Skip to Content
0
Former Member
Jun 15, 2009 at 09:47 PM

Button in a table row to get value of a column.

135 Views

Hello,

I am following [this thread|problem-with-getting-table-element's-table-row] to get the value of a column up on button click (the button is in the same row).

Here is the code in wdDoModify ()

if (firstTime)
	  {
		IWDButton button = (IWDButton) view.getElement("TableCellEditor");
		button.mappingOfOnAction().addSourceMapping("ScheduledCourses", "row");
	  }

Here is the code in the button action()

 public void onActionRegisterStudent(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent, com.gfc.hr.training.wdp.IPrivateCourseRegistrationCompView.IScheduledCoursesElement row )
  {
    //@@begin onActionRegisterStudent(ServerEvent)
	wdContext.nodeScheduledCourses().setLeadSelection(row.index());
    //@@end
  }

The context node for the table is "ScheduledCourses"

When I click the button, I get an exception....

com.sap.tc.webdynpro.services.exceptions.WDIllegalArgumentException: Parameter ScheduledCourses not found