Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

difference between

Can someone clearly explain in words, what exactly is the difference between wdContext() and wdThis()

.When shud we use which one while we write the coding for the view and controller ??

Thanx in advance

Edited by: pankaj mathur on Sep 10, 2008 2:43 PM

Former Member

During coding, the most generic situations where these 2 are used are,

1. you have to use wdThis if you want to call an action, a method, or a event handler which is defined either in your view or in your controller.

2. you have to use wdContext if you want to "get" or "set" values from or to the "node" and "attribute" (it could be a model node, model attribute,value node or value attribute).

so your next question:

Is this true that wdThis is generally used during the View coding when the data is available at the view context. Whereas wdContext() is used when the data is available at the controller context ??

- this is not true, if you understand the above mentioned 2 points.

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question