I am using the modal window to add data into database and required a refresh on the scheduler after that. I am referring to another post in this forum and write my code as this
[in the scheduler page javascript]
modal.closed = function () {
if (this.result && this.result.refresh) {
__doPostBack(id.refreshButton, '');
}
and
[ hidden refresh button]
<div style="display:none">
<asp:Button id="ButtonRefresh" runat="server" OnClick="ButtonRefresh_Click" />
</div>
[code behind]
protected void ButtonRefresh_Click(object sender, EventArgs e)
{
LoadResourcesAndEvents();
}
[in the add page code behind]
//insert into database code....
Hashtable ht = new Hashtable();
ht["refresh"] = "yes";
Modal.Close(this,ht);
but i get this error in "DataItem doesn't hold any source object." in my DayPilotScheduler1_BeforeEventRender.
Please help.