I have the following method that has the OnKeyDownHandler event and I can only send it two parameters and I want to send it a list as well (FileInformation FilesList)
private void OnKeyDownHandler(object sender, FileInformation FilesList, KeyEventArgs e)
{
if (e.Key == Key.Return)
{
TextBox tb = ((TextBox)sender);
new ConnectorCfdiTool.ViewModel.MainToolVM().BuscarCommand(tb.Text, FilesList);
}
}
So I have it in the xaml
<TextBox Name="UserInput" LostFocus="UserInput_LostFocus" HorizontalAlignment="Left" Height="23" Margin="565,35,0,0" VerticalAlignment="Top" Width="191" KeyDown="OnKeyDownHandler" />