Avoiding UpdateData

Introduction

Microsoft does not adequately document the correct way to work with controls. It is left up to the programmer to somehow magically infer the correct way to do this. Unfortunately, all of the evidence suggests that UpdateData is the correct way to handle the problem of accessing control information while working inside a dialog. This is not correct. In fact, it is dangerous to use it. It is simply the wrong way to go about it.

After I posted this essay, one reader, Doug Harrison, sent me a critique. I'm including his comments at the end, because some of them point out some potential flaws in my approach, and are valid points. I also disagree with a couple, and I'll tell you why, and you can judge for yourself what you want to do. But a Wave of the Flounder Fin to Doug, who took the time to send me a message.

You might also like...

Comments

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.” - Rich Cook