X
X
Xnter2022-01-24 00:11:03
C++ / C#
Xnter, 2022-01-24 00:11:03

How to add a variable to the click handling?


61edc3e04cbd8745616212.jpeg
Tell me how to pass 2 arrays to the click function
61edc448e6834347959048.png
and is it real?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
@
@insighter, 2022-01-24
@Xnter

give me 2 arrays

Where to pass where they are created these arrays? If in the form, then they are already available.
If your event handler is in another object (not a form method), then the form can be reached via sender:
... (object sender, ...)
{
    var form = (Form)((ButtonExtendet)sender).Parent;
    form ... доступны все свойства и методы формы
}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question