can you please evaluate option to add additional (optioned) button "Save&Close" the same way as "Save" button is. When clicking this button, system should ask user to save changes(Yes/No dialog) and then execute standard "exit" event(same way as File->Exit does).
Button should be added near "Save button" as proposed in a following picture:
Save&Close combined button in a designer sugestion
Re: Save&Close combined button in a designer sugestion
Hello, Frenk.
You could use next code to add a button.
Thank you.
You could use next code to add a button.
Code: Select all
<body>
<form id="form1" runat="server">
<div>
<cc2:StiMobileDesigner ID="StiMobileDesigner1" runat="server" />
</div>
</form>
<script type="text/javascript">
var saveAndExitButton = jsStiMobileDesigner1.StandartSmallButton("saveAndExitButton", null, null, "Save.png", null);
saveAndExitButton.style.margin = "0 5px 0 5px";
//if you want override button image, use this code
//saveAndExitButton.image.src = "https://www.stimulsoft.com/favicon.png";
saveAndExitButton.action = function () {
jsStiMobileDesigner1.SendCommandSaveReport();
jsStiMobileDesigner1.SendCommandExitDesigner();
}
var toolBarTable = jsStiMobileDesigner1.options.toolBar.firstChild;
var saveAndExitCell = toolBarTable.rows[0].insertCell(1);
saveAndExitCell.appendChild(saveAndExitButton);
</script>
</body>
Re: Save&Close combined button in a designer sugestion
works perfectly, thank you.
Re: Save&Close combined button in a designer sugestion
Hello,
Glad to help you!
Have a nice day.
Glad to help you!
Have a nice day.