I am working on a C# Windows Form project and I need to access the controls on a form from a separate class within the project. can anyone help me with this?
davieJohnson
6
Newbie Poster
Recommended Answers
Jump to PostYou could pass the controls you want to access to this class?
Jump to PostHi,
There are few ways to this. One of it is by sending IntPtr pointing to COntrol's handle. Here is the code.
[Form1]
public partial class Form1 : Form { private static IntPtr m_oControlHandle; public Form1() { InitializeComponent(); } private void Form1_Load(object sender, EventArgs e) …
All 5 Replies
sachintha81
17
Junior Poster in Training
everhett.raman
0
Newbie Poster
Mitja Bonca
557
Nearly a Posting Maven
davieJohnson
6
Newbie Poster
Mitja Bonca
557
Nearly a Posting Maven
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.