!--a11y-->
Supplying the Context with DataYou have to supply the business graphic’s context with data. You can do this in the wdDoInit method (or in a supply function) in the controller.
For
more information read the
documentation on the
supply function.
To generate the coding for the implementation of the controller click the button Implementation.
Enter the following coding in the method wdDoInit. Make sure you enter the coding in the user coding area, that is, between the characters //@@begin wdDoInit()and //@@end.
/** Hook method called to initialize controller. */ public void wdDoInit() { //@@begin wdDoInit() IPrivateSimpleGraphicsView.IANode aNode = wdContext.nodeA();
IPrivateSimpleGraphicsView.IAElement elm; for (int i = 0; i < 10; i++) { elm = wdContext.createAElement(); elm.setCategoryText("Kategorie " + i); elm.setSeries1Value(i); elm.setSeries2Value(10 - i); aNode.addElement(elm); } //@@end }
|
You have now implemented the method wdDoInit. It fills the context with data when the controller is initialized.
