Forum Discussion

pdfrig's avatar
pdfrig
Brass Contributor
Feb 03, 2022
Solved

JSON formatting not sticking in SharePoint Online List Form

In the past couple of months, I noticed that when I try to configure the layout on the SharePoint list form, it doesn't stick.  This has been happening on the new lists that we've been creating.  Even if I clear the cache, the JSON formatting still doesn't stick, even tried using a very simple format and copied the code from MS, and it still doesn't work.  If I click on the first couple of items, looks like the formatting was there, but after clicking on the 3rd list item, all the formatting goes away.  But then, it works fine on one of my other machines.  However, some of the users are also seeing the same issue.  We've checked Windows version, browser version, tested with Edge and Chrome, and Microsoft Lists desktop app, same behavior.   Anyone else having this issue?   

  • Another update and just tried this right now. I saw from another post for a different issue that they changed the list settings - >Advanced Settings - > set Offline Client Availability to No. When I did this on the lists I was having issues with, it worked! the formatting sticks. I'll check again next week and make sure. Let me know if this works for you guys.

15 Replies

  • DavePoint's avatar
    DavePoint
    Copper Contributor

    The offline client availability hack didn't work for me. (My form has informational columns in the header and footer — they used to show columns that were enabled in the view and hidden from the form, but that stopped working last week.) What restored the header and footer was enabling the missing columns with the form's Edit Columns checkbox and then hiding them again with a conditional statement. I used this:

    =if(1==2, true, false)

    Since 1 doesn't equal 2, the column is always hidden from the body of the form, but I can display its value in the header and footer using JSON. Without the conditional statement, the column appears in the body and the header or footer.

     

  • Mark Allotey's avatar
    Mark Allotey
    Copper Contributor
    Yes, I am getting this too. very annoying. Seen a few people reporting this.
    • KaraLynnMcGinn's avatar
      KaraLynnMcGinn
      Brass Contributor

      pdfrigand Mark Allotey 

      Same this kept happening to me... I kept adding the JSON to Configure Layout, looks perfect, then after a browser refresh, the JSON had been removed. I had tried Chrome and Edge. Just tried Firefox and it STUCK! The JSON is still there after a browser refresh. Hoping it stays for good.

       

      Update... this isn't good... now it's stuck in there and when I go back in to edit the JSON, it's showing as blank again, but the previous formatting I added is there. and, I can't overwrite it with new JSON. UGH!

       

      Okay another update... I followed this video tutorial here:

      https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=&cad=rja&uact=8&ved=2ahUKEwjgtPCls_j1AhWHHjQIHTWrDOQQwqsBegQIBhAB&url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3Dye3-kGsTy-4&usg=AOvVaw0T04tlwyN5NOCGM3ix2iRE

      and used her JSON code and it seems to be really sticking now. She is using Chrome in the video and I am using Firefox. I refreshed, cleared browser cache, closed and reopened my browser and the JSON is still there and functioning to where I can update it and it overwrote my old code.

      • pdfrig's avatar
        pdfrig
        Brass Contributor

        KaraLynnMcGinn - Thanks for sharing!  We use Edge in our firm, although some users are allowed to use Chrome, Edge is our official browser.  But it doesn't work in Chrome either.  The custom formatting works fine on Edge/Chrome on one of my machines, but not the other.  But other users are having the same issue as well.  Also another interesting thing I found is from list view, if you click on New Item and copy the link or copy the link from one of the entries, if you paste in a new window, the formatting is intact!      

        I've been working with Edge Support and SPO.  We tested also in I.E. Mode and it worked.  But we wouldn't want to use I.E. for this.  I'm still working with them so hopefully they can come up with a solution that will work with Edge, will keep you all posted.  

Resources