---
title: "Regulator 2005 & GUI threads goo- news on both?"
url: "https://osherove.com/blog/2005/5/2/regulator-2005-amp-gui-threads-goo-news-on-both.md"
canonical: "https://osherove.com/blog/2005/5/2/regulator-2005-amp-gui-threads-goo-news-on-both.html"
published: "2005-05-02T19:21:00"
updated: "2005-05-02T19:21:00"
tags: ["Architecture", "Cool Tools", "Regex"]
author: "Roy Osherove"
description: "I've kept mostly quiet for the past N weeks because of holidays+illness. It gave me time to geek out and start working on a fresh new version of The Regulator (aptly dubbed \"Regulator 2005\"). Boy am I a happy camper.…"
usage: "Licensed under CC BY 4.0 — reuse, quote and adapt with attribution (Roy Osherove, link to the original page)."
license: "https://creativecommons.org/licenses/by/4.0/"
---

# Regulator 2005 & GUI threads goo- news on both?

By Roy Osherove May 2, 2005 In [Architecture](https://osherove.com/blog/category/architecture), [Cool Tools](https://osherove.com/blog/category/cool-tools), [Regex](https://osherove.com/blog/category/regex)

**Historical article** · Originally published May 2, 2005; technical details may be outdated.

I've kept mostly quiet for the past N weeks because of holidays+illness. It gave me time to geek out and start working on a fresh new version of [The Regulator](https://osherove.com/) (aptly dubbed "Regulator 2005"). Boy am I a happy camper. I'm coding nights, I'm coding at lunch breaks, I'm thrilled to be solving new problems.

I plan to "Launch" it at TechEd Europe with maybe a small contest to get a special prize - a customized version of The Regulator for the winner with special splash page and all. What do you think?

For example,  one of the cool things I had to solve was the whole GUI threading glue that you have to do when doing a truly rich GUI app with actually \*responds\* to user actions while doing something. I developed a whole "application block" (or maybe just a helper class or two..) that allow you do solve the threading thing more easily.

A sneak preview might look like this:

**public void DoSomeGUIStuff()**

**{**

   **if(invoker.InvokeSafely(this))**

      **return;**

   **TextBox1.Text = "Something";**

**}**

**public void DoSomeGUIStuff(object sender,EventArgs e)**

**{**

   **if(invoker.InvokeSafely(this,sender,e))**

      **return;**

   **TextBox1.Text = "Something";**

**}**

At the simplest case this is all you need to make the method UI thread safe. For more complex methods, it gets, well, a little more complex, but not very much. There's more, but I'll save that for when I've tested it thoroughly enough. Oh, did I mention that it was written with unit tests?

## More in Architecture

[All posts in Architecture](https://osherove.com/blog/category/architecture)

- Jun 5, 2005

    ### [What's legacy code?](https://osherove.com/blog/2005/6/5/whats-legacy-code.html)

- Jun 5, 2005

    ### [VS 2005 Team System Modeling Strategy and FAQ](https://osherove.com/blog/2005/6/5/vs-2005-team-system-modeling-strategy-and-faq.html)

- May 2, 2005

    ### [What does SOA really mean? One big hype machine](https://osherove.com/blog/2005/5/2/what-does-soa-really-mean-one-big-hype-machine.html)

- Apr 29, 2005

    ### [What does Indigo really mean?](https://osherove.com/blog/2005/4/29/what-does-indigo-really-mean.html)


---

## About the author

**Roy Osherove**: Senior Solutions Architect at AWS working on AI for production and AI-driven development; author of The Art of Unit Testing and Elastic Leadership, with about 20 years of consulting and training on unit testing, TDD, team leadership and continuous delivery.

### Sites

- [RobotPaper](https://robotpaper.ai/): This blog: AI patterns and anti-patterns, AI and coding agents, and engineering leadership.
- [osherove.com](https://osherove.com): Roy's personal site. Author of The Art of Unit Testing and Elastic Leadership; consulting and training on unit testing, TDD, team leadership and continuous delivery, plus about 20 years of blog posts.
- [The Art of Unit Testing](https://www.artofunittesting.com): The Art of Unit Testing, 3rd Edition (Manning): readable, maintainable, trustworthy unit tests, plus TDD workshops in C#, JavaScript, Java and Kotlin.
- [5whys.com](https://www.5whys.com): Roy's writing on software team leadership: self-organizing teams, surviving chaos, learning mode and the Elastic Leadership model.
- [Pipeline Driven](https://pipelinedriven.org): Continuous delivery and DevOps practices: build patterns, pipeline-friendly testing, DevOps metrics and enterprise DevOps.
- [Elastic Leadership](https://www.elasticleadership.com): Elastic Leadership, Roy's framework for software team leaders (survival, learning and self-organizing modes).

### Social

- X: https://x.com/royosherove
- LinkedIn: https://www.linkedin.com/in/osherove/

### Contact

- Contact form: https://forms.gle/jQSx5KoXvrVA1JCK7

### License

Licensed under CC BY 4.0 — reuse, quote and adapt with attribution (Roy Osherove, link to the original page). License: https://creativecommons.org/licenses/by/4.0/
