Skip to Content
0
Former Member
Jun 24, 2015 at 12:35 AM

Uncaught TypeError: d.getDay is not a function

219 Views

Hi All,

I am getting problem in dialogue view when I am clicking on Cancel button, instead of closing the dialogue, its deleting the rows in the table and also showing following uncaught error.

Uncaught TypeError: d.getDay is not a function

I have recently try to convert a date format in one of the views. Not sure if this error is causing because of that. Date format code is as follows.

oTableObjects.addColumn(new sap.ui.table.Column({

label: new sap.ui.commons.Label({

text: "Activated at"

}),

// template: oControl

//Date modification

template: new sap.ui.commons.TextView().bindProperty("text", {

path: 'ACTIVATED_AT',

type: new sap.ui.model.type.Date({pattern:"yyyy-MM-dd HH:mm:ss.ms"})

})

}));

The code for cancel button is as follows:

var loButtonCancel = new sap.ui.commons.Button({

tooltip: "Cancel",

text: "Cancel",

press: function() {

createNote.destroy();

}

Similarly code for Cancel button in other dialogues is

var loButtonCancel = new sap.ui.commons.Button({

tooltip: "Cancel",

text: "Cancel",

press: function() {

loThisDia.destroy();

}

});

Please help me correct this error. Any help would be much appreciated.

Thanks & Regards

Uday Kanike