Update 20250606
This commit is contained in:
@@ -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 { }
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user