In the form.cs file I have two buttons,a memo and a timer.My question is: How do I access the timer or the memo from another cs file?
I’ve tried to make the objects public,but it didn’t work,please give me a source or a project,so I can see where I’m mistaken.
Thanks!
Select your button in designer, go to it’s properties and change ‘Modifiers’ property from Private to Public.
Then you can get access to it from another class, something like this:
Note: it’s just an example and definitely not a pattern for good design 🙂