资源简介
这是一个c#版本的wpf datagrid控件,实现自定义wpf datagrid控件。

代码片段和文件信息
using System;
using System.Collections.objectModel;
using System.ComponentModel;
using System.Data;
using System.Windows.Data;
namespace TestClient.UserControls
{
///
/// Interaction logic for PlacerControl.xaml
///
public partial class AutoFilterPlacerControl : INotifyPropertyChanged
{
public AutoFilterPlacerControl()
{
DataContext = this;
InitializeComponent();
SourceTable = new DataTable();
SourceTable.Columns.Add(new DataColumn(“GameName“ typeof(string)));
SourceTable.Columns.Add(new DataColumn(“Creator“ typeof(string)));
SourceTable.Columns.Add(new DataColumn(“Publisher“ typeof(string)));
SourceTable.Columns.Add(new DataColumn(“Owner“ typeof(string)));
var row = SourceTable.NewRow();
SourceTable.Rows.Add(row);
row[“GameName“] = “World Of Warcraft“;
row[“Creator“] = “Blizzard“;
row[“Publisher“] = “Blizzard“;
row[“Owner“] = “Mark“;
row = SourceTable.NewRow();
SourceTable.Rows.Add(row);
row[“GameName“] = “Halo“;
row[“Creator“] = “Bungie“;
row[“Publisher“] = “Microsoft“;
row[“Owner“] = “Bill“;
row = SourceTable.NewRow();
SourceTable.Rows.Add(row);
row[“GameName“] = “Gears Of War“;
row[“Creator“] = “Epic“;
row[“Publisher“] = “Microsoft“;
row[“Owner“] = “Steve“;
codeViewer.LoadData(this.GetType().Name);
}
DataTable _sourceTable;
public DataTable SourceTable
{
get
{
return _sourceTable;
}
set
{
_sourceTable = value;
NotifyPropertyChanged(“SourceTable“);
}
}
public event PropertyChangedEventHandler PropertyChanged;
private void NotifyPropertyChanged(String info)
{
if (PropertyChanged != null)
{
PropertyChanged(this new PropertyChangedEventArgs(info));
}
}
private void UserControl_Loaded(object sender System.Windows.RoutedEventArgs e)
{
}
}
public class Student
{
public string FirstName { get; set; }
public string LastName { get; set; }
public int? RollNumber { get; set; }
}
}
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 778752 2017-01-04 22:52 ExtendedGrid.dll
文件 957440 2016-12-29 12:00 Fluent.dll
文件 593920 2017-01-04 21:28 ICSharpCode.AvalonEdit.dll
文件 134144 2017-01-04 22:52 ImagePackage.dll
文件 18432 2017-01-04 22:52 MultiEventCommandBinder.dll
文件 3238 2016-12-29 12:05 UserControls\AutoFilterPlacerControl.xaml
文件 2609 2016-12-29 12:05 UserControls\AutoFilterPlacerControl.xaml.cs
文件 1834 2016-12-29 12:05 UserControls\CodeViewer.xaml
文件 1127 2016-12-29 12:05 UserControls\CodeViewer.xaml.cs
文件 3165 2016-12-29 12:05 UserControls\ColumnChooserPlacerControl.xaml
文件 2247 2016-12-29 12:05 UserControls\ColumnChooserPlacerControl.xaml.cs
文件 3120 2016-12-29 12:05 UserControls\ColumnInformationSave.xaml
文件 2696 2016-12-29 12:05 UserControls\ColumnInformationSave.xaml.cs
文件 3759 2016-12-29 12:05 UserControls\ColumnSplitterPlacerControl.xaml
文件 3923 2016-12-29 12:05 UserControls\ColumnSplitterPlacerControl.xaml.cs
文件 3170 2016-12-29 12:05 UserControls\CopyPastePlacerControl.xaml
文件 2245 2016-12-29 12:05 UserControls\CopyPastePlacerControl.xaml.cs
文件 3934 2016-12-29 12:05 UserControls\ExortToCsvPlacerControl.xaml
文件 3282 2016-12-29 12:05 UserControls\ExortToCsvPlacerControl.xaml.cs
文件 4067 2016-12-29 12:05 UserControls\ExortToPdfPlacerControl.xaml
文件 3391 2016-12-29 12:05 UserControls\ExortToPdfPlacerControl.xaml.cs
文件 4083 2016-12-29 12:05 UserControls\ExportToExcelPlacerControl.xaml
文件 3477 2016-12-29 12:05 UserControls\ExportToExcelPlacerControl.xaml.cs
文件 4272 2016-12-29 12:05 UserControls\FooterPlacerControl.xaml
文件 2583 2016-12-29 12:05 UserControls\FooterPlacerControl.xaml.cs
文件 5148 2016-12-29 12:05 UserControls\FrozenRowsPlacerControl.xaml
文件 3254 2016-12-29 12:05 UserControls\FrozenRowsPlacerControl.xaml.cs
文件 5151 2016-12-29 12:05 UserControls\GroupingPlacerControl.xaml
文件 3150 2016-12-29 12:05 UserControls\GroupingPlacerControl.xaml.cs
文件 3444 2016-12-29 12:05 UserControls\MultiTrippleSortPlacerControl.xaml
文件 2256 2016-12-29 12:05 UserControls\MultiTrippleSortPlacerControl.xaml.cs
............此处省略17个文件信息
相关资源
- 用WPF开发的多人聊天室 语言C#
- datagridview控件美化
- WPF控件库HandyControl
- c#DataGridView单元格合并
- WPF
- c# wpf实现的上位机
- VisionPro控件在WPF 应用
- WPF使用MVVM
- winform实现饼状图、柱状图、折线图(
- C#中WPF联合Halcon的一个学习(解决内存
- WPF CEFSHARP 支持 MP4
- WPF贝塞尔曲线
- WPF 简单控件集
- WPF鼠标拖动控件源码
- wpf开发教程
- AduMusic迷你音乐盒WPF源码
- WPF PDF封装(放大、缩小、单页、双页
- C# .NET5.0(net core)基于WPF(XAML)开发
- WPF MVVM 基础入门
- wpf echart
- windorm 加载WPF控件 ,实现dxf文件显示
- WPF Control Development
- wpf Dock window
- WPF 隐蔽查看股票行情工具
- WPF控件库(HandyControl)
- 别踩白块wpf 源码
- WPF贪吃蛇
- WPF Task 多任务
- WPF path动画
-
C#读取xm
l文件数据。显示在datagrid
评论
共有 条评论