I have an interface in Visual C #. In this interface I have a class named T50 that contains all the variables I need.
I've already implemented a button where the object created by the T50 class was saved. I can save and read this object (Using serialize).
But when I reread a saved object I need to fill in the part of the interface that the user already had.
Within my T50 class there is a function to do this.
private void button_t50_carregar_Click(object sender, EventArgs e)
{
// Código de ler o dado
// Usa uma função para preencher os dados
T50_Data.PreencheInterface(T50_Data);
}
But within this function I need to access all the Controls of my Form to adjust them (Button, Textbox, DataGridViwe ....).
I know how to get them individually, for example
public void PreencheInterface (T50 T50Data, TextBox text)
{
}
Is there a way for me to pass all of them at the same time?