cancel
Showing results for 
Search instead for 
Did you mean: 

UI5 custom Control

Former Member
0 Kudos

Hi,

I am new to SAPUI5 and am trying to develop a small mobile application.

I created a small on the fly custom control by following: https://openui5.hana.ondemand.com/docs/guide/OnTheFlyControlDefinition.html+&cd=4&hl=en&ct=clnk&gl=u...

While trying to use it in my application, I simply created a folder called js and stored the code for the control in a JS file.

I am using XML as my base view creator, for mobile applications. When I tried to use the new control on the XML page, I get an error which says that the control could not be found. I have included src of the js file in the html page as well.

Am I doing something wrong or am I not doing something crucial to get the XML view to find the control?

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Ananya,

check if you have in your controller set the path as it is shown here: , paragraph 3.

Regards,

Peter

Former Member
0 Kudos

I tried doing this, However, on trying to execute the code, I get an error saying: Resource Not Found... It points to the new Control's JS file.

I am unable to resolve this...

Former Member
0 Kudos

Did you register your control  folder path using sap.ui.localResources('folder-name'); ?