Author Archive

Convert a number to an Excel column heading

As part of a project I’ve been working on in the office, I had a need to programmatically work with Microsoft Excel. This is a fairly easy process with the Interop.Excel DLL, however, sometimes there can be a need to work with language data types and convert them in a way that can be used

Use images as button icons in Dynamo components

Dynamo is becoming a bit of a ‘thing’ in the office recently, with a shift in some technology focus as Dynamo and the rest of BIM begin to really take hold in industry. As such, some people are trying to get ahead of the game and make sure their Grasshopper components can also work in

Random string generator for Grasshopper

As a bit of something quick and fun, I produced a random string generator component for Grasshopper. It’s a simple component with three inputs to control the number, length and chars included of strings and returns one output, a list of randomly generated strings. Quite what you’d wish to use this for I don’t know,

How should you be coding Grasshopper components?

Grasshopper has evolved somewhat since its beginnings and it’s becoming increasingly common to find Grasshopper developers out there looking to push the boundaries of visual programming/modelling. For the most part, scripting for Grasshopper was done within the built-in scripting components (for Python, C#, etc). It allows people with little programming knowledge to create their custom

C# GUI – blurring focus on a parent window when using pop-up windows

Continuing with the C# GUI theme of this week (using group boxes, finding UI controls using strings and making child windows stay on top), this post looks at how we can focus a users attention on a new window by blurring the parent. In some cases your software may have an additional window (as a

C# GUI – Make a child window stay on top at all times

Continuing on from my previous work this week (in using group boxes and finding UI controls by name), this post looks at how we can force a child window (such as a pop-up) to stay on top of the main window at all times. This can be particularly useful when you want the new window

C# GUI – Finding controls by name

With a C# GUI created in WPF, you can end up with large amounts of mark-up code in XAML defining your UI, and even more C# controlling the UI behaviours and propagating changes to the back-end. In some cases, you might have twenty controls with similar names. Hard-coding the name of the control each time

C# GUI with WPF – Using Group boxes

A short UI development post today following some work I’ve completed on building a new GUI for a project at work. Hopefully this post gives a brief introduction to those wanting to also use group boxes to group content, and how to resolve the issue where using group boxes may give you the error “The

Motorcycle Module 1 test

Things have been a bit quiet round here this month for one reason or another. The biggest reason is my research focus this month shifted slightly away from software development and into report writing. It started with my end of year report is due in with the university in January which needed drafting for supervisors

Upload files via FTP with C#

Prior to going to India, I was looking at using sockets to send data between C# applications and web servers. While the work was interesting and a good insight into the use of NodeJS and various other pieces of the technology, it was unfortunately unable to achieve the task I had been set. This was