I am already out, and won't be contributing anything after this post because of your hostile attitude. But lets summarise over the details, shall we ? I think you're a troll.
Being honest, I wish you had grabbed a book on C# or done some research before writing this.
- What is meant to be passed into getControl ?
- What should be passed in for f, name and type ?
- What does this have to do with a button ?
- What is all this about a handler for a button ?
- What are you trying to achieve, (not in code) but in general?
- Lastly, why are your objects static?
Surely if you're passing around forms and such, you'd be better working with instances?
If you can answer some of the questions, maybe we can help you build what you need. As it stands, what you wrote doesn't make a lot of sense for something of much use.
I asked you a number of questions, both myself and John wanted you to answer. In order for us to help you, you need to help us by providing us with answers for what we asked you for. Which you did not. You ignored us all, and then you come back a day later and call us gay fags and then you have the cheek to expect further help without apologising.
calling a click event from within the button event does not do anything either.
Well that's nice to know. And what do you think we can do about that when we don't know how you wrote your code inside your button event? And they are not called
button events, they are
button methods with
event arguments. My theory is that you are likely needing to invoke click on the button you want to programmatically click. I think this because you appear to be throwing forms around in your get controls method. I could simply provide you with the answer to that problem, but I feel an apology is in order after your little outburst.
One should be able to understand what I am trying to do fromt his photo.
Well, you know they say a picture tells a thousand words. Hmm, in this case, it doesn't tell me anything about what you are trying to do, because you haven't explained that yet again, nor have you showed your code for this button method which you keep talking of.
When a talent is selected its photo and label need to be added to the build.
Build, what build? You're talking as if we are sitting beside you looking at your screen. We are each thousands of miles away from you with no clue what build you are referring to. Is this where we play guessing games?
I use one event handler for all my button clicks. I use statics because its convenient not only for events but for creating controls. But whatever your saying. Its a simple problem. How to access a sperate control from within an event handler.
Well that shows how much you know. And if its a simple problem, why don't you fix it? If that control is on another form, you need to either disable cross thread operations or invoke the control with a delegate. If this is something you've not done before, its actually not simple for the later option. And for the previous, I wouldn't advocate as its terrible practice and will likely cause more issues. Actually we don't know, because you are not showing the relevant code.
This problem is preventing me from finishing this project.
We could never have guessed as much. I thought you just came here for a quick trolling session and fling a few insults. Also on post 15, John was summarising to me about the questions I had asked you to update us on, so that we had more info to work with and provide you with an answer. If this is something you are unfamiliar with, this is how we build communication, and speculate to formulate ideas on the forums while we conjure up fresh thoughts on how we could best answer your question and wait for you to reply.
The only person here holding you back; is yourself. If you won't provide clear descriptive answers to what you were asked, you clearly are a troll.