Native Phone Call

You can make phone calls by using the native phone application. The following example shows how to launch the default phone application on the mobile device.

const Page = require('sf-core/ui/page');
const extend = require("js-base/core/extend");
const Color = require('sf-core/ui/color');
const Button = require('sf-core/ui/button');
const FlexLayout = require("sf-core/ui/flexlayout");
const Application = require("sf-core/application");
var page1 = extend(Page)(
function(_super) {
var btnCallPhone = new Button({
height: 75,
width: 200,
margin: 10,
text: "Call Smartface",
backgroundColor: Color.BLUE,
textColor: Color.WHITE,
alignSelf: FlexLayout.AlignSelf.CENTER,
onPress: function(){"tel:+1-650-617-3265");
this.layout.flexWrap = FlexLayout.FlexWrap.WRAP;
this.layout.flexDirection = FlexLayout.FlexDirection.ROW;
this.layout.justifyContent = FlexLayout.JustifyContent.CENTER;
module.exports = page1;