The rows.load() method loads resource data from the specified URL using an AJAX call.

Declaration

DayPilot.Scheduler.rows.load(url[, success[, error]])

Parameters

  • url (string) - JSON endpoint URL

  • success (function) - optional callback invoked after the resources have been loaded

  • error (function) - optional callback invoked if the request fails

Notes

The HTTP method (GET/POST) is specified using the rowsLoadMethod property.

Invalid Responses

In Pro since version 2026.4.7086, an empty response body, malformed JSON, or valid JSON that is not an array invokes the error callback. Return [] for an empty collection; an empty body or null is not an empty collection.

args.request contains the original XMLHttpRequest, including for empty responses. args.exception contains the parsing or validation exception when applicable. Invalid responses do not call the success callback or replace the existing collection.

Example

dp.rows.load("/api/resources", (args) => {
  dp.message("Resources loaded");
});

See Also

DayPilot.Scheduler.rowsLoadMethod

DayPilot.Scheduler Class

Availability

Availability of this API item in DayPilot editions:

ProductLitePro
DayPilot for JavaScript