Added even SingelClick event for checking list
This commit is contained in:
14
tomcatAnalys/ListItem.cs
Normal file
14
tomcatAnalys/ListItem.cs
Normal file
@ -0,0 +1,14 @@
|
||||
namespace tomcatAnalys
|
||||
{
|
||||
public class ListItem
|
||||
{
|
||||
public string GarantiNr { get; set; }
|
||||
public string GarantiJob { get; set; }
|
||||
public string[] xmlRader { get; set; }
|
||||
public override string ToString()
|
||||
{
|
||||
string returStr = $"Garanti: {GarantiNr} Jobnr: {GarantiJob} ex: {xmlRader[6].Substring(0, 50) + "..."}";
|
||||
return returStr;
|
||||
}
|
||||
}
|
||||
}
|
||||
1
tomcatAnalys/frmStart.Designer.cs
generated
1
tomcatAnalys/frmStart.Designer.cs
generated
@ -67,6 +67,7 @@
|
||||
this.lbInstances.Size = new System.Drawing.Size(744, 407);
|
||||
this.lbInstances.Sorted = true;
|
||||
this.lbInstances.TabIndex = 2;
|
||||
this.lbInstances.Click += new System.EventHandler(this.lbInstances_Click);
|
||||
this.lbInstances.DoubleClick += new System.EventHandler(this.lbInstances_DoubleClick);
|
||||
//
|
||||
// btnClose
|
||||
|
||||
@ -107,22 +107,20 @@ namespace tomcatAnalys
|
||||
|
||||
private void lbInstances_DoubleClick(object sender, EventArgs e)
|
||||
{
|
||||
ListItem aktRad= (ListItem)lbInstances.Items[lbInstances.SelectedIndex];
|
||||
fileWindow.FileShowerFileName = aktRad.GarantiNr+"-"+aktRad.GarantiJob;
|
||||
CheckClickedRow();
|
||||
}
|
||||
|
||||
private void CheckClickedRow()
|
||||
{
|
||||
ListItem aktRad = (ListItem)lbInstances.Items[lbInstances.SelectedIndex];
|
||||
fileWindow.FileShowerFileName = aktRad.GarantiNr + "-" + aktRad.GarantiJob;
|
||||
fileWindow.FileShowerBox.Lines = aktRad.xmlRader;
|
||||
fileWindow.ShowDialog();
|
||||
}
|
||||
}
|
||||
|
||||
public class ListItem
|
||||
{
|
||||
public string GarantiNr { get; set; }
|
||||
public string GarantiJob { get; set; }
|
||||
public string[] xmlRader { get; set; }
|
||||
public override string ToString()
|
||||
private void lbInstances_Click(object sender, EventArgs e)
|
||||
{
|
||||
string returStr = $"Garanti: {GarantiNr} Jobnr: {GarantiJob} ex: {xmlRader[6].Substring(0, 50) + "..."}";
|
||||
return returStr;
|
||||
CheckClickedRow();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -58,6 +58,7 @@
|
||||
<Compile Include="frmStart.Designer.cs">
|
||||
<DependentUpon>frmStart.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="ListItem.cs" />
|
||||
<Compile Include="Program.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<EmbeddedResource Include="frmFileShower.resx">
|
||||
|
||||
Reference in New Issue
Block a user