Skip to main content
All docs
V24.1

Use JsonDataSource

The JsonDataSource component allows you to obtain data from a Web service endpoint, text file, or JSON string.

Configure the JsonDataSource object at runtime as follows:

  1. Use the JsonSource property to specify the JSON data location.
  2. Optional. Use the Schema property to specify JSON nodes to retrieve data.
  3. Use the Fill or FillAsync method to retrieve data.

The JsonDataSource object uses the open source Newtonsoft.Json library for .Net Framework platforms. Install the Newtonsoft.Json package if your application does not reference this library.

For .NET 6+ platforms, JsonDataSource uses System.Text.Json. Set the DevExpress.DataAccess.Native.Json.JsonLoaderHelper.ProcessingLibrary property to NewtonsoftJson to use the Newtonsoft.Json library instead.