| View previous topic :: View next topic |
| Author |
Message |
famousmassacre1 Expert Cheater
Reputation: 0
Joined: 30 Jun 2008 Posts: 113 Location: San Antonio Texas
|
Posted: Sat Mar 28, 2009 12:19 pm Post subject: [request] Macro |
|
|
can someone make me a macro that refreshes the page 20 times every 19 minutes 57 seconds?
_________________
|
|
| Back to top |
|
 |
talkerzero Grandmaster Cheater
Reputation: 1
Joined: 24 Jul 2008 Posts: 560 Location: California
|
Posted: Sat Mar 28, 2009 5:01 pm Post subject: |
|
|
C++
| Code: | UINT i = 0;
for(;; Sleep((60000 * 19) + 57000))
for(i = 0; i < 20; i++)
keybd_event(VK_F5, NULL, NULL, NULL); |
Oh and, make sure firefox/IE's window stays focused.
|
|
| Back to top |
|
 |
oib111 I post too much
Reputation: 0
Joined: 02 Apr 2007 Posts: 2947 Location: you wanna know why?
|
Posted: Sat Mar 28, 2009 5:54 pm Post subject: |
|
|
I prefer to actually let the page refresh before telling FF/IE8 to refresh again lol (the loop will go by so fast you won't be able to refresh). Also, don't use keybd_event. Try this:
| Code: |
INPUT input[2];
input[0].type = INPUT_KEYBOARD;
input[0].ki.wVk = VK_F5;
input[0].ki.dwFlags = 0;
input[0].ki.time = 0;
input[0].ki.dwExtraInfo = 0 ;
input[1].type = INPUT_KEYBOARD;
input[1].ki.wVk = VK_F5;
input[1].ki.dwFlags = KEYEVENTF_UP;
input[1].ki.time = 0;
input[1].ki.dwExtraInfo = 0 ;
while(bExit == FALSE) {
SendInput(2, &input, sizeof(INPUT)*2);
sleep(8550);
}
|
_________________
| 8D wrote: |
cigs dont make people high, which weed does, which causes them to do bad stuff. like killing |
|
|
| Back to top |
|
 |
talkerzero Grandmaster Cheater
Reputation: 1
Joined: 24 Jul 2008 Posts: 560 Location: California
|
Posted: Sat Mar 28, 2009 11:58 pm Post subject: |
|
|
| oib111 wrote: | | I prefer to actually let the page refresh before telling FF/IE8 to refresh again lol (the loop will go by so fast you won't be able to refresh). |
Here..
| Code: | UINT i = 0;
INPUT input[2];
input[0].type = INPUT_KEYBOARD;
input[0].ki.wVk = VK_F5;
input[0].ki.dwFlags = 0;
input[0].ki.time = 0;
input[0].ki.dwExtraInfo = 0 ;
input[1].type = INPUT_KEYBOARD;
input[1].ki.wVk = VK_F5;
input[1].ki.dwFlags = KEYEVENTF_UP;
input[1].ki.time = 0;
input[1].ki.dwExtraInfo = 0 ;
for(;; Sleep((60000 * 19) + 57000))
for(i = 0; i < 20; i++, Sleep(8550))
SendInput(2, &input, sizeof(INPUT)*2); |
|
|
| Back to top |
|
 |
oib111 I post too much
Reputation: 0
Joined: 02 Apr 2007 Posts: 2947 Location: you wanna know why?
|
Posted: Sun Mar 29, 2009 8:08 am Post subject: |
|
|
Lol, I'm saying if you refresh in a loop like yours the page won't actually be able to refresh because you 'll have hit F5 20 times at an extremely fast speed.
_________________
| 8D wrote: |
cigs dont make people high, which weed does, which causes them to do bad stuff. like killing |
|
|
| Back to top |
|
 |
|