Search

How to Identify the Antivirus Software Installed on a PC Using C#
By Tan Lee Published on Feb 15, 2025 253

To identify the antivirus software installed on a PC using C#, you can query Windows Management Instrumentation (WMI) for the relevant information. Specifically, you can access the AntiVirusProduct class in the Security Center API to retrieve details about the installed antivirus.

Read more
How to define a monitor as the primary display in C#
By Tan Lee Published on Feb 14, 2025 311

In this article, I'll walk you through how to dynamically change the primary display on Windows 10 using C# in a WinForms application.

Read more
How to render a XML file or string into a TreeView in C#
By Tan Lee Published on Feb 14, 2025 329

In this guide, we'll explore how to render an XML file or string into a TreeView control in your WinForms application.

Read more
Billion Laughs XML DoS Attack on .NET Framework C# Xml Parser
By Tan Lee Published on Feb 14, 2025 181

The Billion Laughs attack is a denial-of-service (DoS) vulnerability targeting XML parsers, particularly those that support Document Type Definition (DTD).

Read more
How to Retrieve Titles and Process IDs of Taskbar Applications in C#
By Tan Lee Published on Feb 14, 2025 241

In this guide, learn how to obtain a list of all Windows processes with visible windows (i.e., those shown on the taskbar) using C#.

Read more
Implementing Copy, Cut, and Paste Context Menu in a Rich Text Box in C#
By Tan Lee Published on Feb 14, 2025 295

This guide will show you how to create a context menu with basic text editing options like Copy, Cut, and Paste for a RichTextBox in a WinForms application.

Read more
How to allow only plain text inside a RichTextBox in C#
By Tan Lee Published on Feb 14, 2025 220

By default, most rich text boxes do not support pasting text through drag and drop.

Read more
C# CSV
By Tan Lee Published on Feb 11, 2025 165

In C#, you can read and write CSV data using various methods.

Read more
How to check potential XSS characters in C#?
By Tan Lee Published on Nov 06, 2024 482

To check for potential Cross-Site Scripting (XSS) vulnerabilities, you'll need to identify characters or payloads that might be used to inject malicious scripts into web pages.

Read more
How to change the buffer size of StreamWriter in C#
By Tan Lee Published on Dec 26, 2024 998

StreamWriter buffers data by writing it to an internal character array, which has a default size of 1024 bytes and a minimum size of 128 bytes. Once the buffer is full, or when the StreamWriter is disposed, the buffer is flushed to the underlying stream.

Read more