Update 20250606

This commit is contained in:
Stefan Hutter
2025-06-06 09:13:32 +02:00
parent 10343fcbab
commit 85ff87dc62
106 changed files with 1312 additions and 298 deletions

View File

@@ -4,11 +4,13 @@ using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using OnDoc.Klassen;
using Syncfusion.WinForms.Controls;
using Syncfusion.WinForms.DataGrid.Enums;
using Windows.UI.Xaml.Controls;
namespace OnDoc.Diverses
@@ -106,5 +108,64 @@ namespace OnDoc.Diverses
{
sfCalendar1_DoubleClick(sender, e);
}
private void GridData_DrawCell(object sender, Syncfusion.WinForms.DataGrid.Events.DrawCellEventArgs e)
{
//try
//{
// if (e.Column.MappingName == "SAREC00")
// {
// e.Handled = true;
// var selectedItem = e.DataRow;
// var dataRow = (e.DataRow.RowData as DataRowView).Row;
// e.Style.Font.Strikeout = true;
// Pen borderPen = new Pen(Color.LightGray);
// e.Graphics.DrawLine(borderPen, e.Bounds.Right, e.Bounds.Top, e.Bounds.Right, e.Bounds.Bottom);
// e.Graphics.DrawLine(borderPen, e.Bounds.Left, e.Bounds.Bottom, e.Bounds.Right, e.Bounds.Bottom);
// return;
// }
//}
//catch { }
}
private void GridData_QueryCellStyle(object sender, Syncfusion.WinForms.DataGrid.Events.QueryCellStyleEventArgs e)
{
//try
//{
// if (e.Column.MappingName == "SAREC00")
// {
// var selectedItem = e.DataRow;
// var dataRow = (e.DataRow.RowData as DataRowView).Row;
// e.Style.Font.Strikeout = true;
// return;
// }
//}
//catch { }
}
private void GridData_QueryRowStyle(object sender, Syncfusion.WinForms.DataGrid.Events.QueryRowStyleEventArgs e)
{
try
{
if (e.RowType == RowType.DefaultRow)
{
var dataRowView = e.RowData as DataRowView;
if (dataRowView != null)
{
var dataRow = dataRowView.Row;
var cellValue = dataRow["SAREC00"].ToString();
if (cellValue == "7")
e.Style.Font.Strikeout = true;
}
}
}
catch { }
}
}
}