Button - OnClick no longer working

Hi Guys,

Before the Christmas break I was working on a display form with a number of buttons where I had the OnClick setup to open other forms in a dialog, this was working 100%.

I have come back today to continue development and the functionality seems to have stopped working and I cannot understand why, I get no errors in the console but the dialog simply does not open, the code in the OnClick is as follows

sessionStorage.clear();
var companyNameId = fd.itemId;
sessionStorage.setItem('companyNameId', companyNameId);
openDialogBox(_spPageContextInfo.webAbsoluteUrl +'/SitePages/PlumsailForms/Notes/Item/NewForm.aspx?');

function openDialogBox(Url) {
	debugger;
	var ModalDialogOptions = {
	url:Url,
    	width:800,
    	height:600,
    	showClose: true,
    	allowMaximize: true,
    	dialogReturnValueCallback: function(dialogResult) {
    		if (dialogResult != SP.UI.DialogResult.cancel) {
    			window.location.reload();
    		}
    	}
	};
	SP.SOD.execute('sp.ui.dialog.js', 'SP.UI.ModalDialog.showModalDialog', ModalDialogOptions);
};

Any Help appreciated

Dear Tony,

Please refer to the topic: Get Current Item Id and refresh on callback issues