Thursday 19 June 2008

Passing references to variables between forms in c#

Somedays i forget everything i've learnt. Being a VB programmer in the past has instilled some bad habits on how to think about forms, their controls, methods or properties when in C#.

Luckily ahmedilyas has posted a lovely little tutorial here. Ok, perhaps we shouldn't be referencing a form with another form. If doing everything by the book you should be building some data classes external to both forms and allow them to access the data through those. But today i catch myself modifying someone else's code and the oppotunity isn't there to completely rework the class definitions.