https://github.com/bytehide/csharp-qr-generator
A simple C# QR Generator made with Windows Forms
https://github.com/bytehide/csharp-qr-generator
csharp dotnet qrcode qrcode-generator winforms
Last synced: 9 months ago
JSON representation
A simple C# QR Generator made with Windows Forms
- Host: GitHub
- URL: https://github.com/bytehide/csharp-qr-generator
- Owner: bytehide
- License: mit
- Created: 2023-05-24T14:12:56.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2023-05-24T14:27:28.000Z (almost 3 years ago)
- Last Synced: 2025-06-06T22:41:31.144Z (10 months ago)
- Topics: csharp, dotnet, qrcode, qrcode-generator, winforms
- Language: C#
- Homepage: https://www.bytehide.com/
- Size: 8.79 KB
- Stars: 4
- Watchers: 0
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Simple Csharp QR Generator
This is a simple QR Code generator application using C#. It allows users to input text and generate a QR code, which can then be saved as an image file.

## Features
- Generate QR codes from user-provided text
- Save the generated QR code as an image file
- User-friendly interface with centered controls
## Dependencies
- [ZXing.Net](https://github.com/micjahn/ZXing.Net) for generating QR codes
## Usage
1. Open the project in your favorite C# development environment
2. Add the ZXing.Net library to your project
3. Build and run the application
4. Input your desired text and click the "Generate" button to generate a QR code
5. Click the "Save" button to save the QR code as an image file
## Code Explanation
The main class `Form1` is responsible for handling the UI and generating the QR codes. The UI elements are setup in the constructor, and the QR code generation is done using the `GenerateQRCode` method.
The `GenerateQRCode` method takes an input text, creates a `ZXing.BarcodeWriterPixelData` object with the specified QR code format and dimensions, and then generates a Bitmap representing the QR code.
The event handlers for the "Generate" and "Save" buttons are responsible for generating the QR code using the user-provided text and saving it as an image file.
## More Information
For more information on QR code generation in C#, check out this in-depth guide: [C# QR Code Generator](https://www.bytehide.com/blog/qr-generator-csharp)