The AL developer preview is still evolving with frequent updates. Follow us on the Dynamics NAV Team Blog for the announcements.

AsObject Method

Converts the value in a JsonToken to a JsonObject data type.

JsonObject := JsonToken.AsObject


Type: JsonToken

A JsonToken for which IsObject returns true. If the JsonToken does not represent a JSON object, a run-time error occurs.

Return Value

Type: JsonObject

The returned JsonObject contains the same data as the JsonToken, but allows object-specific operations to be performed on it.

See Also

HTTP, JSON, TextBuilder, and XML API
Getting Started with AL
Developing Extensions