-
大小: 116KB文件类型: .zip金币: 1下载: 0 次发布日期: 2021-06-01
- 语言: 其他
- 标签: DataGridView 过滤 DataGridView
资源简介
DataGridView过滤(附带完整代码及示例)
代码片段和文件信息
//---------------------------------------------------------------------
// Copyright (C) Microsoft Corporation. All rights reserved.
//
//THIS CODE AND INFORMATION ARE PROVIDED AS IS WITHOUT WARRANTY OF ANY
//KIND EITHER EXPRESSED OR IMPLIED INCLUDING BUT NOT LIMITED TO THE
//IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
//PARTICULAR PURPOSE.
//---------------------------------------------------------------------
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Diagnostics;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.Windows.Forms.Visualstyles;
using System.Collections;
using System.Reflection;
namespace DataGridViewAutoFilter
{
///
/// Provides a drop-down filter list in a DataGridViewColumnHeaderCell.
///
public class DataGridViewAutoFilterColumnHeaderCell : DataGridViewColumnHeaderCell
{
///
/// The ListBox used for all drop-down lists.
///
private static FilterListBox dropDownListBox = new FilterListBox();
///
/// A list of filters available for the owning column stored as
/// formatted and unformatted string values.
///
private System.Collections.Specialized.OrderedDictionary filters =
new System.Collections.Specialized.OrderedDictionary();
///
/// The drop-down list filter value currently in effect for the owning column.
///
private String selectedFilterValue = String.Empty;
///
/// The complete filter string currently in effect for the owning column.
///
private String currentColumnFilter = String.Empty;
///
/// Indicates whether the DataGridView is currently filtered by the owning column.
///
private Boolean filtered;
///
/// Initializes a new instance of the DataGridViewColumnHeaderCell
/// class and sets its property values to the property values of the
/// specified DataGridViewColumnHeaderCell.
///
/// The DataGridViewColumnHeaderCell to copy property values from.
public DataGridViewAutoFilterColumnHeaderCell(DataGridViewColumnHeaderCell oldHeaderCell)
{
this.ContextMenuStrip = oldHeaderCell.ContextMenuStrip;
this.ErrorText = oldHeaderCell.ErrorText;
this.Tag = oldHeaderCell.Tag;
this.ToolTipText = oldHeaderCell.ToolTipText;
this.Value = oldHeaderCell.Value;
this.ValueType = oldHeaderCell.ValueType;
// Use Hasstyle to avoid creating a new style object
// when the style property has not previously been
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 914 2011-08-02 16:35 WindowsFormsApplication2\WindowsFormsApplication2.sln
文件 25088 2011-08-04 15:38 WindowsFormsApplication2\WindowsFormsApplication2.suo
目录 0 2011-08-04 13:57 WindowsFormsApplication2\WindowsFormsApplication2\
文件 159 2011-08-04 13:57 WindowsFormsApplication2\WindowsFormsApplication2\app.config
目录 0 2011-08-01 15:16 WindowsFormsApplication2\WindowsFormsApplication2\bin\
目录 0 2011-08-04 13:58 WindowsFormsApplication2\WindowsFormsApplication2\bin\Debug\
文件 35840 2011-08-04 15:23 WindowsFormsApplication2\WindowsFormsApplication2\bin\Debug\WindowsFormsApplication2.exe
文件 159 2011-08-04 13:57 WindowsFormsApplication2\WindowsFormsApplication2\bin\Debug\WindowsFormsApplication2.exe.config
文件 69120 2011-08-04 15:23 WindowsFormsApplication2\WindowsFormsApplication2\bin\Debug\WindowsFormsApplication2.pdb
文件 11600 2011-08-04 15:24 WindowsFormsApplication2\WindowsFormsApplication2\bin\Debug\WindowsFormsApplication2.vshost.exe
文件 159 2011-08-04 13:57 WindowsFormsApplication2\WindowsFormsApplication2\bin\Debug\WindowsFormsApplication2.vshost.exe.config
文件 490 2010-03-17 22:39 WindowsFormsApplication2\WindowsFormsApplication2\bin\Debug\WindowsFormsApplication2.vshost.exe.manifest
目录 0 2011-08-01 15:16 WindowsFormsApplication2\WindowsFormsApplication2\bin\Release\
文件 68492 2011-08-04 13:46 WindowsFormsApplication2\WindowsFormsApplication2\DataGridViewAutoFilterColumnHeaderCell.cs
文件 6939 2011-08-04 13:46 WindowsFormsApplication2\WindowsFormsApplication2\DataGridViewAutoFilterTextBoxColumn.cs
文件 9232 2011-08-04 15:22 WindowsFormsApplication2\WindowsFormsApplication2\Form1.cs
文件 8666 2011-08-04 14:14 WindowsFormsApplication2\WindowsFormsApplication2\Form1.Designer.cs
文件 6017 2011-08-04 14:14 WindowsFormsApplication2\WindowsFormsApplication2\Form1.resx
目录 0 2011-07-20 13:54 WindowsFormsApplication2\WindowsFormsApplication2\obj\
目录 0 2011-07-20 13:54 WindowsFormsApplication2\WindowsFormsApplication2\obj\x86\
目录 0 2011-08-04 15:23 WindowsFormsApplication2\WindowsFormsApplication2\obj\x86\Debug\
文件 4440 2011-07-22 13:42 WindowsFormsApplication2\WindowsFormsApplication2\obj\x86\Debug\DesignTimeResolveAssemblyReferences.cache
文件 6410 2011-08-04 15:23 WindowsFormsApplication2\WindowsFormsApplication2\obj\x86\Debug\DesignTimeResolveAssemblyReferencesInput.cache
文件 380 2011-08-04 14:14 WindowsFormsApplication2\WindowsFormsApplication2\obj\x86\Debug\GenerateResource.read.1.tlog
文件 926 2011-08-04 14:14 WindowsFormsApplication2\WindowsFormsApplication2\obj\x86\Debug\GenerateResource.write.1.tlog
目录 0 2011-08-04 13:57 WindowsFormsApplication2\WindowsFormsApplication2\obj\x86\Debug\TempPE\
文件 4608 2011-08-04 13:57 WindowsFormsApplication2\WindowsFormsApplication2\obj\x86\Debug\TempPE\Properties.Resources.Designer.cs.dll
文件 1217 2011-08-04 15:24 WindowsFormsApplication2\WindowsFormsApplication2\obj\x86\Debug\WindowsFormsApplication2.csproj.FileListAbsolute.txt
文件 35840 2011-08-04 15:23 WindowsFormsApplication2\WindowsFormsApplication2\obj\x86\Debug\WindowsFormsApplication2.exe
文件 180 2011-08-04 14:14 WindowsFormsApplication2\WindowsFormsApplication2\obj\x86\Debug\WindowsFormsApplication2.Form1.resources
文件 69120 2011-08-04 15:23 WindowsFormsApplication2\WindowsFormsApplication2\obj\x86\Debug\WindowsFormsApplication2.pdb
............此处省略10个文件信息
- 上一篇:信息论与编码第五章课后习题答案
- 下一篇:STC12交流信号采样电路图
相关资源
- Fiddler简单过滤规则1.ffx
- 一种基于多贝叶斯算法的垃圾邮件过
- 过滤脏字算法
- 基于用户的协同过滤和基于内容的混
- DataGridView中数据存入数据库方法
- 论文研究-一种绕过应用防火墙过滤规
- 皮尔森相关系数 之用户推荐的协同过
- 敏感词过滤+最新敏感词库
- 一个简单的LINUX防火墙
- DataGridView 显示数组中的元素
- 我的构架::::用包过滤技术实现
- vue自定义过滤器,例如给文字加颜色
-
Item ba
sed collaborative filtering recommen - windows内科安全与驱动开发,minifilte
- TestCenter过滤器的使用
- 读取Excel文件到DataGridView
- 自己写的一个分页控件,可以实现d
- datagridview增加汇总行 源码
- 实现TreeView和ListView合体效果的控件
- 过滤无效密码,过滤密码小于八位
- 验证用户有没有登陆的过滤器
- 脏话过滤代码和几千个敏感词汇.zip
- 无线433远距离/低电量时的杂波过滤方
- linux下使用原始套接字抓包并发现网络
- datagridview添加一个合计行[美好实用版
- 基于双隶属度模糊支持向量机的邮件
- 17 机器学习案例——基于朴素贝叶斯
- springboot+shiro代码demo
- 基于管道过滤器风格的单词排序程序
- 一个可折叠行的DataGridView控件
评论
共有 条评论