Mach 6 Science
Life, Research, Music

Program to get download link from flashgot

Source: tombkeeper
Original link: http://www.bkjia.com/aqgjrj/499358.html


Code

#include

int WINAPI WinMain(HINSTANCE hInstance,
HINSTANCE hPrevInstance,
LPSTR lpCmdLine,
int nCmdShow)
{
if(OpenClipboard(NULL))
{
HGLOBAL clipbuffer;
char * buffer;
EmptyClipboard();
clipbuffer = GlobalAlloc(GMEM_DDESHARE, lstrlen(lpCmdLine)+1);
buffer = (char*)GlobalLock(clipbuffer);
strcpy(buffer, lpCmdLine);
GlobalUnlock(clipbuffer);
SetClipboardData(CF_TEXT,clipbuffer);
CloseClipboard();
return 0;
}
else
{
return -1;
}
}

No comments yet

Comment