How To

How to change ‘Edit Top 200 Rows’ and ‘Select Top 1000 Rows’ in SQL
By Tan Lee Published on Dec 24, 2024 560

In SQL Server Management Studio (SSMS), when you right-click on a table, you can use the context menu to quickly run commands like Select Top 1000 Rows or Edit Top 200 Rows.

How to Encode and Decode URL in C#
By Tan Lee Published on Dec 11, 2024 1.45K

In C#, URL encoding and decoding can be performed using the System.Net.WebUtility class or System.Uri class.

Fixing Invalid Parameter Type in Attribute Constructor
By Tan Lee Published on Dec 21, 2024 425

When attempting to pass a parameter to the constructor of a custom attribute, you may encounter one of the following compiler errors:

Building Your First App with HTMX and .NET - Part II
By Tan Lee Published on Feb 07, 2025 141

In this episode, we’ll enhance our Articles app by adding an article editing feature. Users will be able to edit article details with a clean and responsive interface.

Working with HTMX and Razor Components
By Tan Lee Published on Feb 07, 2025 220

In .NET 8, working with Razor components has become an efficient way to handle HTML rendering in a clean and reusable format.

Getting Started with HTMX
By Tan Lee Published on Feb 07, 2025 215

HTMX is a JavaScript library that lets you integrate AJAX functionality into HTML directly through HTML attributes.

Build a server-side web app with HTMX in C#
By Tan Lee Published on Feb 07, 2025 201

Combine .NET with C# and HTMX for a smooth development experience that delivers dynamic front-end interactivity without any JavaScript.

How to Use HttpClient to GET JSON from API endpoint in C#
By Tan Lee Published on Jan 09, 2025 434

Why not create a method that can make a GET request to an API and directly return the response as an object?

JWT Token Expiry Timestamp in C#
By Tan Lee Published on Jan 10, 2025 529

To decode a JWT token and extract its expiration time (expiry), you can follow these steps in C#.

How to Send x-www-form-urlencoded Data with HttpClient in C#
By Tan Lee Published on Jan 09, 2025 618

To post x-www-form-urlencoded data in C# using HttpClient, you can follow these steps:

How to use NetEscapades.​AspNetCore.​SecurityHeaders
By Tan Lee Published on Jan 03, 2025 515

NetEscapades.AspNetCore.SecurityHeaders is a .NET library that helps you easily set HTTP security headers in ASP.NET Core applications to improve security by protecting against various types of attacks (like XSS, clickjacking, etc.).

How to setup a webapi controller for multipart/form-data
By Tan Lee Published on Feb 16, 2024 773

If you uploaded file through webapi in angularjs and encountered the following error: ExceptionMessage=No MediaTypeFormatter is available to read an object of type ‘HttpPostedFileBase’ from content with media type 'multipart/form-data'.