- using System;
- using System.Runtime.InteropServices;
- using System.Windows.Forms;
- namespace WindowsFormsApplication1
- {
- public partial class Form1 : Form
- {
- private static int _hookHandle = 0;
- [DllImport("user32.dll", CharSet = CharSet.Auto, CallingConvention = CallingConvention.StdCall)]
- public static extern int SetWindowsHookEx(int idHook, HookProc lpfn, IntPtr hInstance, intthreadId);
- [DllImport("user32.dll", CharSet = CharSet.Auto, CallingConvention = CallingConvention.StdCall)]
- public static extern bool UnhookWindowsHookEx(int idHook);
- [DllImport("user32.dll", CharSet = CharSet.Auto, CallingConvention = CallingConvention.StdCall)]
- public static extern int CallNextHookEx(int idHook, int nCode, IntPtr wParam, IntPtr lParam);
- [DllImport("user32.dll", CharSet = CharSet.Auto, CallingConvention = CallingConvention.StdCall)]
- public static extern short GetKeyState(int nVirtKey);
- public delegate int HookProc(int nCode, IntPtr wParam, IntPtr lParam);
- public const int WH_KEYBOARD_LL = 13;
- public const int VK_LCONTROL = 0xA2;
- public const int VK_RCONTROL = 0xA3;
- public Form1()
- {
- InitializeComponent();
- SetHook();
- }
Sunday, November 17, 2013
C# System wide shortcut keys | Global Hot-key in C#
Tuesday, November 12, 2013
Port Check Tool In C#
Simple port check tool for windows
Tool Download here...
C# Source download
Tool Download here...
Link | Type | Size |
7z | ||
exe |
C# Source download
- using System;
- using System.Windows.Forms;
- using System.Net.Sockets;
- namespace PortCheck
- {
- public partial class Form1 : Form
- {
- public Form1()
- {
- InitializeComponent();
- }
- private void btnCheck_Click(object sender, EventArgs e)
- {
- TcpClient cli = new TcpClient();
- int port = 0;
- string ip;
- try
- {
- port = Convert.ToInt32(txtPort.Text.Trim());
- ip = txtIP.Text.Length > 7 ? txtIP.Text : "0.0.0.0";
- cli.Connect(ip, port);
- MessageBox.Show(cli.Connected == true ? "Port Opened" : "Port Closed", this.Text);
- }
- catch (Exception ex) { MessageBox.Show(ex.Message, this.Text); }
- }
- }
- }
Monday, November 11, 2013
Limitations of SQL Server 2008 R2 Express
1. Maximum 10 GB per database.
2. Uses no more than 1 processor.
3. Uses no more than 1 GB of internal memory.
4. NO Maintenance plans
5. NO Database mail
6. NO User instances
7. SQL Server Agent
8. NO Full-text search
Google Start Rewards Program
Program Rules
Reward amounts
Rewards for qualifying submissions will range from $500 to $3,133.7. The final amount is always chosen at the discretion of the reward panel and is based on our judgment of the complexity and impact of the patch.
Subscribe to:
Posts (Atom)