Hide a Drive on your PC

If you prefer the USB to keep its drive letter but just want Windows (and consequently Outlook) to hide its icon completely from view, you can hide specific drive letters via the registry.

  1. Press Win + R, type regedit, and hit Enter.
  2. Navigate to: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer
    (If the Explorer folder isn't there, right-click Policies, select New > Key, and name it Explorer).
  3. Right-click in the right pane, select New > DWORD (32-bit) Value.
  4. Name it NoDrives.
  5. To calculate the value, you use a specific number based on the letter your USB uses. Double-click NoDrives, switch the Base to Decimal, and enter the corresponding number:
    • D: 8 | E: 16 | F: 32 | G: 64 | H: 128
  6. Click OK and restart your computer. The drive letter will be completely invisible in the attachment browsing window, but you can still access it by typing F: (or whichever letter it is) manually into any address bar.

SharePoint Template Size

In SSSE I needed to move some content but creating a Template failed with the Include Content selected because it exceeded the Template size of limit of 50MB. Luckily in SharePoint On-Premise you can adjust the Maximum Template size up to 500MB. Open SharePoint PowerShell As Administrator and run the following 2 lines to increase to 100MB (Double the default size). Then run a IISRESET right after.

[Microsoft.SharePoint.Administration.SPWebService]::ContentService.MaxTemplateDocumentSize = 104857600
[Microsoft.SharePoint.Administration.SPWebService]::ContentService.Update()

Details can be found in this search Increase SP Template Size.

ASPNETCORE_ENVIRONMENT

When you publish an ASP.NET Core app to IIS you will need the following setting in your Web.Config file in order to retrieve the value. Normally, in development in Visual Studio, you have this setting in launchSettings.json file. However, this file is not published so the variable needs to be in the Web.Config file.

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <system.web>
    <!-- 100 MB in KB -->
    <httpRuntime maxRequestLength="102400" executionTimeout="3600" />
  </system.web>

  <system.webServer>
    <security>
      <requestFiltering>
        <!-- 100.5 MB in bytes -->
        <requestLimits maxAllowedContentLength="105857600" />
      </requestFiltering>
    </security>

    <aspNetCore processPath=".\ApplicationName.exe" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" hostingModel="inprocess">
      <environmentVariables>
        <environmentVariable name="ASPNETCORE_ENVIRONMENT" value="DEV" />
      </environmentVariables>
    </aspNetCore>
    
  </system.webServer>
</configuration>

 

JSON or Access Denied

In ASP.NET when calling a method in a Controller you might see this message.

This is actually an HTML page being returned with "Access Denied", however you can't see this as JSON can't parse it. It's caused by the user not having enough permission to call the method in the controller because the entire controller has an overriding higher privilege. 

The solution is to update the OnAuthorization method to handle this.

public void OnAuthorization(AuthorizationFilterContext context)

 

ToolPane Disabled in SharePoint

As of September 2026, the SharePoint Subscription Edition CU, the ToolPane used for editing SharePoint Web Parts has been disabled. This means that every time a CU is installed you must re-enable the ToolPane in order to edit Web Part. It might be a good thing to keep this disabled unless it's required.

To enable it again open SharePoint Management Shell As Administrator and execute this script.

Get-SPSite -Limit All | ForEach-Object {
    Write-Host "Enabling ToolPane: $($_.Url)" -ForegroundColor Cyan
    Enable-SPToolPane -Identity $_.Url
}

To disable it run this script.

Get-SPSite -Limit All | ForEach-Object {
    Write-Host "Enabling ToolPane: $($_.Url)" -ForegroundColor Cyan
    Enable-SPToolPane -Identity $_.Url
}

You might see this error

Check SharePoint SSE September 2026 CU Notes.

 https://support.microsoft.com/en-us/servicing/office/hotfix/sharepoint/5002908

Telerik Kendo UI

When creating a Kendo UI DataGrid, do not use the type of datetime, like used in the database. Only use the type of date. Otherwise the console will complain of a javascript error.

Use this <field name="CreateDate" type="date" editable="false"></field>

Not this:  <field name="CreateDate" type="datetime" editable="false"></field>

Hot-Reload Error

I installed Visual Studio 2026 18.7.0 update and then could no longer run Hot-Reload.

The error message threw me off because it has always worked. After a couple of days I was annoyed so looked into the error more closely and sure enough, I had code inside <toolbar> tags on a page I had not touched in about 6-8 months. I guess this VS update makes thing a bit more restrictive for the better. Anyway, I changed the code to a javascript function and then I was able to run the Hot-Reload successfully after that.

avoid NaN (Not a Number)

This is how to avoid NaN (Not a Number)

        // Get the Text value from the BT Amount Display that will be in Currency format
        let btAmount = $("#BtamountDisplay").val();
        console.log("BT Amount Before Conversion: " + btAmount);

        // Remove $ or , characters to get just the number
        let cleanString = btAmount.replace(/[$, ]/g, '');
        let dblBtAmount = parseFloat(cleanString);

        console.log("BT Amount After Conversion: " + dblBtAmount);

 

Kendo UI: Paging message not showing in Data Grid

From this Post: Paging message not showing in Kendo UI for jQuery | Telerik Forums

I have a Kendo UI data grid inside a modal dialog and the Page Message of 1 - 10 of 50 (for example) is not showing in the bottom right.

The reason is because the UI component does some internal calculations and decides to hide it if it deems the box is too small. So, to always you need to add the following to the Pageable() section. Responsive(false) is all you need so that the component does not hide it!

.Pageable(pager => pager
           .Messages(messages => messages.Display("Records from {0} to {1} of {2}").Responsive(false))
        )
@(Html.Kendo().Grid<Models.Address>(Model.addresses)
        .Name("grid")
        .Scrollable()
        .Pageable(pager => pager
           .Messages(messages => messages.Display("Records from {0} to {1} of {2}").Responsive(false))
        )
        .Sortable()        
        .Columns(columns =>
        {
            columns.Bound(column => column.Id);
            columns.Bound(column => column.StreetAddress);
            columns.Bound(column => column.City);
            columns.Bound(column => column.Zip);
            columns.Bound(column => column.Id).ClientTemplate("<input type='button' class='k-button' onclick=\"location.href='./AddressEdit/#=Id#'\" value='Edit' />")
             .Title(" ");
        })
        .DataSource(ds => ds
            .Ajax()
            .PageSize(20)
            .ServerOperation(false)
        )
    )

 

Unable to pass more than 1 parameter using @Url.Action

From here: c# - Unable to pass more than 1 parameter using @Url.Action - Stack Overflow

Now the second parameter is passed in!!

$("#filesTemplate").kendoUpload({
	async: {
        autoUpload: false,
        saveUrl: "@Html.Raw(@Url.Action("Attachments_Save", "Upload", new { parentId, baseTableName }))",
        removeUrl: "@Url.Action("Attachments_Delete", "Upload")"
     }
});