Method One:

Code:
SendMessage(GetForegroundWindow(),WM_LBUTTONDOWN,NULL,MAKELPARAM(0,0));
SendMessage(GetForegroundWindow(),WM_LBUTTONUP,NULL,MAKELPARAM(0,0));
Method Two

Code:
mouse_event(MOUSEEVENT_LEFTDOWN,0,0,0,0);
mouse_event(MOUSEEVENT_LEFTUP,0,0,0,0);
Method Three

Code:
    INPUT    Input={0};
    Input.type      = INPUT_MOUSE;
    Input.mi.dwFlags  = MOUSEEVENTF_LEFTDOWN;
    SendInput(1,&Input,sizeof(INPUT));

    ZeroMemory(&Input,sizeof(INPUT));
    Input.type      = INPUT_MOUSE;
    Input.mi.dwFlags  = MOUSEEVENTF_LEFTUP;
    SendInput(1,&Input,sizeof(INPUT));
}
Anyone know of any other ways?