Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 3019

Problem with eventhandler and this

$
0
0

Hi

I got a problem with "this" in an eventhandler, when i create a new entity using the odata.v2 model.

 

I wan´t to call a method on another controller, when the update is successful.

 

oModel.create('/data', oEntry, {success: this._oListController.createOk});

 

The this._oListController.createOk method is called, but in the method "this" point to the window object. How can i change the reference to another type?

 

Kind regards,

Kim


Viewing all articles
Browse latest Browse all 3019

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>