Quantcast
Channel: SCN : All Content - SAPUI5 Developer Center
Viewing all articles
Browse latest Browse all 6178

Hi,How to align text?

$
0
0

Hi,

 

 

   var label1= new sap.m.Label();

   label1.setText("Material Purchase Requisition");

   label1.setTextAlign(new sap.ui.core.TextAlign.Center);

 

above one is my code

 

and below is my error

Uncaught TypeError: string is not a function

 

what might be my mistake and please let me know is there any chance of adding CSS directly in  .js file?

 

Thanks in advance

..

..


Viewing all articles
Browse latest Browse all 6178

Trending Articles



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