UpdatePage.qml Example File
persistentobjects/assets/UpdatePage.qml
import bb.cascades 1.0
Page {
titleBar: TitleBar {
title: qsTr("Persistent Objects Sample")
}
Container {
layout: DockLayout {
}
Container {
horizontalAlignment: HorizontalAlignment.Center
verticalAlignment: VerticalAlignment.Center
leftPadding: 30
rightPadding: 30
TextField {
id: idField
horizontalAlignment: HorizontalAlignment.Center
hintText: qsTr("ID")
}
TextField {
id: firstName
horizontalAlignment: HorizontalAlignment.Center
hintText: qsTr("first name")
}
TextField {
id: lastName
horizontalAlignment: HorizontalAlignment.Center
hintText: qsTr("last name")
}
Button {
horizontalAlignment: HorizontalAlignment.Center
text: qsTr("Update")
onClicked: {
_app.updateObject(idField.text, firstName.text, lastName.text);
}
}
}
}
}