資源簡介
打開項目重新添加FastWin32的引用,dll在bin\Release目錄下找得到。編譯好的都在這個目錄,全部解壓后運行“注入Demo.exe”。FastWin32的源碼反編譯就可以得到
代碼片段和文件信息
using?System;
using?System.Text;
using?System.Windows.Forms;
namespace?注入Demo
{
????internal?static?class?ExceptionCatcher
????{
????????///?
????????///?指示是否使用過
????????///?
????????private?static?bool?_used;
????????private?static?Func?_callback;
????????///?
????????///?自動捕獲所有異常
????????///?
????????public?static?void?Catch()
????????{
????????????Catch(null);
????????}
????????///?
????????///?自動捕獲所有異常,并使用回調方法
????????///?
????????///?回調方法,返回值如果為 ,則不彈窗顯示,如果為 ,則彈窗顯示
????????public?static?void?Catch(Func?callback)
????????{
????????????if?(!_used)
?????????
- 上一篇:QQ聊天系統
- 下一篇:C#從入門到精通PPT文本
評論
共有 條評論