A chronicle of issues encountered in SharePoint

Category: SharePoint 2019

How to Remove Excess White Space on the Right Side of SharePoint Pages

Modern Site pages often have a large amount of unused white space on the sides of the active content area. The bulk of the nonsense found on Google for resolving this tends to fall into one of these four categories:

  1. It’s not possible to change it.  Deal with it.  (This is the standard answer from Microsoft moderators.)
  2. I’m having this problem too!   (I don’t care. Provide a solution or be quiet.)
  3. Add a vertical column on the right side from the Section menu.  (We know about this. It’s not relevant.)
  4. Unrelated gibberish.  (My personal favorite.)

The short answer is:

  1. Use F12 (aka “Developer Tools”) to figure out the exact name of the content area that is undersized. In our case it’s “CanvasZone”.
  2. Add a Content Editor Web Part  (You may have to add the free “Modern Content Editor Web Part” from Github.)
  3. Add CSS code to the CEWP above to set the width to 100%.

So try this code:

<style text="type/css">
.CanvasZone {
    max-width: 100% !important;
    width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}
</style>

__________________________________________________________________

Full disclosure: we didn’t do it the above way. While looking at the page in F12, one developer saw that our page was already calling JQuery.  So he asked an AI tool to write the appropriate JQuery code.  It did and it worked.  So here is the code we used:

<script>
JQuery(document).ready(() => {
JQuery(".CanvasZone").css("max-width",'100%')
});
</script>

If your page is not already calling JQuery, you can call JQuery from within the code snippet.  Here is how to do that:

<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.1/jquery.min.js"></script>
<script>
JQuery(document).ready(() => {
 JQuery(".CanvasZone").css("max-width",'100%')
});
</script>

**Update Apr 24, 2025: Here is a super helpful video from SPJeff that covers this very topic. Great minds think alike. I wish I had found his video before going to all of this work!

Clever Techniques for Dealing with Folder Sprawl

I cannot count the number of clients I’ve encountered who have treated the default document library on a SharePoint site as the *only* document library they could use.  So they filled it up with folders, then sub-folders, then sub-sub-folders, etc.  It makes for a difficult conversation.  I usually say “let’s take ALL of the top-level folders and make them each their own document library!”  And then they say “No” because they’ve gotten used to it like this.  And by “this” I mean sprawled and unmanageable, generally.

So if you’ve got sites that have folder sprawl, this article from Veronique Palmer will give your users a little help figuring out how many sub-folders are beneath your top-level folders, and how many items they contain.  It’s a start.  And it’s helpful.

One last piece of advice: if your organization manually provisions sites for users, delete the default “Documents” document library and during the provisioning process, ask your users to think about how many document libraries they’ll probably need going forward.  Get them to provide meaningful document library names.  And then create them for them.

PeoplePicker Issues with SharePoint 2019 in a DMZ

We have the task of installing SharePoint 2019 in a corporate DMZ but then connecting back behind the corporate firewall to the AD instance so our corporate users can connect to the platform via SSO.  We ran a wacky STSADM -O command that allowed us to successfully connect the PeoplePicker in Central Admin to add users to the Farm Admin group but it still fails when trying to add users to the web application (where it’s needed).

So on a call with Microsoft we were referred to the below article by Josh Roark, Sr. Support Escalation Engineer at Microsoft.  I hope it helps you as much as it did us!

https://joshroark.com/sharepoint-how-to-configure-people-picker-for-a-one-way-trust/

Powered by WordPress & Theme by Anders Norén