DEV Community

fischgeek
fischgeek

Posted on

DotNetDates

I made a little diddy I wanted to share with you all. It's nothing too grand or impressive. I just really like how it turned out and even more happy with the cleanliness of the code.

It's a simple form to play around with date formats in .NET. Here's the GitHub and a screenshot.

Alt Text

It was all written with F# (minus the C# Forms project bit). What is neat though is I only laid out the basic locations of where I wanted things to go using FlowLayoutPanels.

Alt Text

Then passed those to my F# to handle the rest.

using System.Windows.Forms; using DotNetDates.FSharp; namespace DotNetDates { public partial class Form1 : Form { public Form1() { InitializeComponent(); var form = this; FormBuilder.Build(form, flpFormatMethods, flpFormatSpecifiers, flpCustomFormats, flpCreateYourOwn, flpCreateYourOwnResult); } } } 
Enter fullscreen mode Exit fullscreen mode

I'm curious to read what you think and thanks for checking it out!

Top comments (0)