Windows
Financial Stress Javascript Humor
C# Visual Studio – Change the AppName on Build
Here’s how to automatically rename your .exe file during build in a C# WinForms (or any .NET Framework) project: Post-build Rename (with dynamic value) Inside Visual Studio:
C# Template – Migration
A Laravel-inspired migration builder for C# WinForms using MySQL. It provides a fluent, intuitive way to manage your database schema through code using MigrationBase, TableBuilder, and ColumnBuilder. Base Class: BaseMigration All migrations should inherit from MigrationBase, which defines the structure and tools needed for schema operations. TableBuilder Usage Used inside CreateTable() to fluently define columns: Example: Available Column Types: Type Method Description Int(name, len) Integer column String(name, len) VARCHAR column Timestamp(name) TIMESTAMP column Boolean(name) TINYINT(1) for true/false values Date(name) Date column DateTime(name) DateTime column Decimal(name, len) Decimal column ColumnBuilder Chainable Methods Each column can be configured using these methods: Method Description PrimaryKey() Sets column as the primary key AutoIncrement() Auto-increment integer Unique() Adds a UNIQUE constraint Default(value) Sets a default value for the column Creating a Migration Step 1: Create a Migration Class Step 2: Run Migration You can manage migrations via your custom migration runner. Here’s an example that runs during LoginForm_Load() and only fires if it’s fired using F5 from Visual Studio: Best Practices