web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Suggested Answer

Create JSON using C/AL in NAV 2016

(0) ShareShare
ReportReport
Posted on by 1,144

Hi,

How do I create a JSON file thru C/AL Code in NAV 2016 Database ?

Kindly inform.

Thanks,

Subrata

I have the same question (0)
  • Community Member Profile Picture
    on at

    You Need to use .net for this as in NAV we can Consume Jason but to write we need to use .net.

  • Suggested answer
    RockwithNav Profile Picture
    8,637 Super User 2025 Season 2 on at

    You need to use Odata.

  • Suggested answer
    Community Member Profile Picture
    on at

    You can download Latest CU of Indian version which has export JSON inbuilt on Posted Sales Invoice or to push your data in web service you can use this URL docs.microsoft.com/.../how-to--use-odata-to-return-obtain-a-json-document

    From 13R2 systems have newtonsoft dll inbuilt so call dotnet variables of that.

    5025.JsonFile.txt

    Sample File :

    {

     "DocumentNo": "101009",

     "Address": {

       "Address1": "Slovenska ccsta 127",

       "City": "MEMA Ljubljana d.o.o."

     },

     "ItemDetails": [

       {

         "ItemNo": "1976-W",

         "PrName": "INNSBRUCK Storage Unit/W.Door"

       },

       {

         "ItemNo": "1964-W",

         "PrName": "INNSBRUCK Storage Unit/G.Door"

       }

     ]

    }

    //Code to Create File in attachment

  • Suggested answer
    ArturV Profile Picture
    225 on at

    Use the JSON Management codeunit.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 2,066

#2
YUN ZHU Profile Picture

YUN ZHU 658 Super User 2025 Season 2

#3
Sumit Singh Profile Picture

Sumit Singh 595

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans