Hi experts,
First of all, I have to mention that I am new at SAPUI5. I follow step by step SAPUI5 tutorials but I have a problem with XML file. The problem is that I put a Button in my XML file, however when I run the project, button does not show up. Could you help me for this matter?
View1.view.XML:
<mvc:View
xmlns="sap.m"
xmlns:mvc="sap.ui.core.mvc"
controllerName="sap.ui.demo.wt.controller.View1">
<Button text="Say Hello" press="onShowHello"/>
</mvc:View>
index.html:
<!DOCTYPE html >
<html>
<head>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta charset="utf-8">
<title>Walkthrough</title>
<script
id="sap-ui-bootstrap"
src="/resources/sap-ui-core.js"
data-sap-ui-theme="sap_bluecrystal"
data-sap-ui-libs="sap.m"
data-sap-ui-compatVersion="edge"
data-sap-ui-preload="async"
data-sap-ui-resourceroots='{
"sap.ui.demo.wt": "./"
}' >
</script>
<script>
sap.ui.getCore().attachInit(function () {
sap.ui.xmlview({
viewName : "sap.ui.demo.wt.view.View1"
}).placeAt("content");
});
</script>
</head>
<body class="sapUiBody" id="__button1">
</body>
</html>