The process of building custom applications and tools that interact with Microsoft SharePoint, including SharePoint Online in Microsoft 365.
Based on your description, I understand that you are trying to hide the "Add New item" and "Edit in grid view" buttons on a SharePoint list Calendar view using JSON view formatting. However, the commandBarProps JSON code you provided is not hiding the buttons as expected, and you need this resolved so users are forced to use your integrated Power Apps form instead.
I tested the exact JSON payload you shared in my environment, and it actually worked perfectly to hide both buttons on a Calendar view. Because it is working as intended out-of-the-box, the issue might be related to how or where the JSON is being applied.
To help narrow this down and resolve the issue, could you check a few things for me?
- Verify the Current View: Please double-check that you are actively applying and saving this JSON to the Calendar view itself and not accidentally editing a different list view (like the All Items view). You can ensure this by switching to the Calendar view first, clicking the view dropdown menu, selecting Format current view, switching to Advanced mode, pasting your code, and hitting Save.
- User Cache vs. Creator View: When you click Save in Advanced mode, do the buttons disappear for you immediately on the screen, but still show up for your users? Or do the buttons remain visible for everyone, including yourself, even after saving and refreshing the page?
- Test on a Clean List: If you create a brand new, clean SharePoint list, set up a temporary Calendar view, and apply this exact same JSON, does the button successfully disappear there? This will help us determine if there is a conflict with existing customizations on your current list.
Let me know what you find after checking these steps, and we can troubleshoot further!
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click ""Comment"".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.