19 Jul, 2009 in Programming by

I’ve created a really simple library in C# for use in any .NET application to interact with the Cli.gs API. Currently there’s only 2 methods: 1. Create – this will take a long URL and optional title to return a shortened URL. The title is used in the back end for the admin to see. […]

9 Jul, 2009 in Programming by

I needed a Day of Week user-control for an ASP.NET web app I’m working on and wanted to use the built-in DayOfWeek enum for the task. Here’s the C# code-behind I put together after a little googling: public override void DataBind() { this.ddlDays.DataSource = this.GetEnumList(typeof(DayOfWeek)); this.ddlDays.DataTextField = "Key"; this.ddlDays.DataValueField = "Value"; this.ddlDays.DataBind(); } private List<KeyValuePair<string, […]