資源簡介
類似spy++,專門針對.net程序的專版。 微軟的那個ManagedSpy太舊了,只能在fm2.0下面玩,編譯也不過運行也不過。 這個是朋友給我的,能編譯并運行。 我vs2013,win7x64.相信其他的vs版本也能運行。

代碼片段和文件信息
using?System;
using?System.Collections.Generic;
using?System.ComponentModel;
using?System.Data;
using?System.Drawing;
using?System.Text;
using?System.Windows.Forms;
using?System.Collections;
namespace?ManagedSpy?{
????///?
????///?This?dialog?allows?the?user?to?filter?events.
????///?Note?that?this?could?be?improved?to?actually?show?_all_?events.
????///?To?do?this?you?would?have?to?look?at?TypeDescriptor.GetEvents?of
????///?the?ComponentType?property?of?the?ControlProxy.
????///?
????public?partial?class?EventFilterDialog?:?Form?{
????????EventFilterList?eventlist?=?new?EventFilterList();
????????internal?EventFilterList?EventList?{
????????????get?{?return?eventlist;?}
????????????set?{?eventlist?=?value;?}
????????}
????????public?EventFilterDialog()?{
????????????InitializeComponent();
????????????this.dataGridView1.DataSource?=?EventList;
????????????this.dataGridView1.Columns[0].Width?=?47;
????????????this.dataGridView1.Columns[1].Width?=?170;
????????}
????????private?void?buttonOK_Click(object?sender?EventArgs?e)?{
????????????this.Close();
????????}
????????private?void?dataGridView1_KeyPress(object?sender?KeyPressEventArgs?e)?{
????????????if?(e.KeyChar?==?(char)Keys.Space)?{
????????????????ToggleSelectedCells();
????????????}
????????}
????????private?void?ToggleSelectedCells()?{
????????????if?(dataGridView1.SelectedCells.Count?>?0)?{
????????????????bool?newValue?=?!EventList[dataGridView1.SelectedCells[0].RowIndex].Display;
????????????????foreach?(DataGridViewCell?cell?in?dataGridView1.SelectedCells)?{
????????????????????if?(cell.ColumnIndex?==?0)?{
????????????????????????cell.Value?=?newValue;
????????????????????}
????????????????}
????????????}
????????}
????????private?void?dataGridView1_CellDoubleClick(object?sender?DataGridViewCellEventArgs?e)?{
????????????ToggleSelectedCells();
????????}
????}
????class?EventFilterList?:?List?{
????????public?EventFilterList()?{
????????????EventDescriptorCollection?edColl?=?TypeDescriptor.GetEvents(typeof(Control));
????????????edColl?=?edColl.Sort();
????????????Add(new?EventFilterLine(“Custom?Events“?true));
????????????for?(int?i?=0;?i?????????????????Add(new?EventFilterLine(edColl[i].Name?true));
????????????}
????????}
????????public?EventFilterLine?this[string?eventName]?{
????????????get?{
????????????????foreach?(EventFilterLine?line?in?this)?{
????????????????????if?(line.EventName?==?eventName)?{
????????????????????????return?line;
????????????????????}
????????????????}
????????????????return?this[0];?//custom
????????????}
????????}
????}
????class?EventFilterLine?{
????????string?eventName;
????????bool?isChecked;
????????public?EventFilterLine(string?eventName?bool?isChecked)??{
????????????this.eventName?=?eventName;
????????????this.isChecked?=?isChecked;
????????}
????????public?string?EventName?{
????????
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2015-01-04?09:29??ManagedSpy-master\
?????文件??????????80??2015-01-04?09:29??ManagedSpy-master\.editorconfig
?????文件?????????154??2015-01-04?09:29??ManagedSpy-master\.gitignore
?????文件???????46080??2015-01-04?09:29??ManagedSpy-master\EULA.doc
?????文件????????1713??2015-01-04?09:29??ManagedSpy-master\ManagedSpy.sln
?????目錄???????????0??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\
?????文件?????????824??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\Delete.bmp
?????文件????????5152??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\EventFilterDialog.Designer.cs
?????文件????????3263??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\EventFilterDialog.cs
?????文件????????5814??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\EventFilterDialog.resx
?????文件?????????824??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\Filter2.bmp
?????文件????????5083??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\HelpAbout.Designer.cs
?????文件?????????328??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\HelpAbout.cs
?????文件???????51004??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\HelpAbout.resx
?????文件???????21465??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\MainForm.Designer.cs
?????文件????????7804??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\MainForm.cs
?????文件???????55098??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\MainForm.resx
?????文件????????7945??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\ManagedSpy.csproj
?????文件????????1777??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\NativeMethods.cs
?????文件?????????824??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\Play.bmp
?????文件?????????467??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\Program.cs
?????目錄???????????0??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\Properties\
?????文件????????1286??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\Properties\AssemblyInfo.cs
?????文件????????3962??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\Properties\Resources.Designer.cs
?????文件????????6645??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\Properties\Resources.resx
?????文件????????1093??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\Properties\Settings.Designer.cs
?????文件?????????249??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\Properties\Settings.settings
?????文件?????????824??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\Refresh.bmp
?????文件?????????824??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\Stop.bmp
?????文件?????????146??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\app.config
?????文件???????29926??2015-01-04?09:29??ManagedSpy-master\ManagedSpy\search.ico
............此處省略25個文件信息
- 上一篇:外部托盤圖標操作例程
- 下一篇:秘密行動V2.0(多種免殺利器一體)
評論
共有 條評論