on 09-16-2014 8:38 PM
Hi,
I have below code to open table in dailog box. When I open this table for the first time, I see everything as expected. But when I open same table again with same button click. I see results from second screen shot where I am not able select the records.. section indicator column is messed up. Let me know if you can help in this.
function SearchEmp(){ | |||||
var oValueHelpDialog = new sap.ui.ux3.ToolPopup({ |
title: "Employee Search",
opener: "idPernr", // locate dialog next to this field
closed: function (oEvent) {
// return selected tabled line/value
var oCore = sap.ui.getCore();
var oEmpInput = oCore.byId("idPernr");
var oContext = oHelpTable.getContextByIndex(oHelpTable.getSelectedIndex());
if (oContext) {
var oSel = oContext.getModel().getProperty(oContext.getPath());
oEmpInput.setValue(oSel["pernr"]);
}; |
}
}); |
var oOkButton = new sap.ui.commons.Button({
text: "OK",
press: function () {
oValueHelpDialog.close(); |
}
});
// I have Data Binding logic (service call) here.
oValueHelpDialog.addButton(oOkButton);
oValueHelpDialog.addContent(oHelpTable); |
oValueHelpDialog.open();
}; |
Image 1: When I click on search button for the first time
Image 2: When I click on search button for the second time
This is fixed now. I had to assign instance to oValueHelpDailog in above code and check if application is calling this declaration second time.
if (!sap.ui.getCore().byId("toolpop")){
var oValueHelpDialog2 = new sap.ui.ux3.ToolPopup("toolpop", {
Now everything inside this IF condition will be called for the first time and issue will be fixed.
Thanks,
Naveen
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
91 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.