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

Re: Uncaught TypeError: Cannot read property 'byId' of undefined

$
0
0

Hi Robin

 

Scenario is like below.

 

First View : contain hyperlink which should open another view in popup.

 

Second View (Popup View) : It actually is combination of 4 xml views embedded into single view and all these 4 views are using single controller .

 

I am able to call and display popup view from hyperlink in First View without any code/just with layout.

 

I already initialized all the 4 xml views of Popup View from component.js.

 

dropDown = sap.ui.getCore().byId("viewId").byId("dropDown"); syntax not working but

 

dropDown = sap.ui.getCore().getElementById("dropDown"); syntax is working.

 

When I try to set model to UI Element using below , it is giving error that setModel is undefined method.

    dropDown.setModel(model);

 

I strongly believe we can use multiple views with single controller under componentization approach.Please share recommendations or what could be the issue for undefined type errors.

 

 

Regards,

Koti Reddy


Viewing all articles
Browse latest Browse all 8623

Trending Articles



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