Jump to content

CTRL Send Error?


 Share

Recommended Posts

Hi,

I was wondering if its my code that is wrong or the ControlSend have error.

I created a macro that do somethings while I am browsing or watching videos.

First it works like how its supposed to work but there are lot of times that my pc seems to have problem while running the program. Problems such. CapsLock malfunctioning, mouse malfunction. Eh ie. left clicking a desktop icon will select it,move it or right click it instead of just selecting it. Well I hope you get what i was trying to say. Its kind of hard to explain. :(

Link to comment
Share on other sites

  • Moderators

Cerro,

I was wondering if its my code that is wrong or the ControlSend have error

If I were a betting man I would put my money on the first of those two options! :)

But unless you show us the code we will never know............. :(

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

Cerro,

If I were a betting man I would put my money on the first of those two options! :)

But unless you show us the code we will never know............. :(

M23

ok later.. its in my usb, ill just look for it. xD

Link to comment
Share on other sites

First thing first..

I know that game bots is not allowed here, but this is not a game bot, just a simple macro to click things. Hope its ok.

HotKeySet("{home}","Start")

HotKeySet("{pause}","pause")

HotKeySet("{end}","End")

pause()

Func Pause()

While 1

Sleep(30)

WEnd

EndFunc

Func End()

Exit

EndFunc

Func Start()

while 1

ControlSend("game","","",3); Send number3 for clicking purposes ^^

Sleep(7000); Wait 7 seconds

ControlSend("game","","","{space}"); Send space for looting purposes ^^

Wend

EndFunc

-------

That's the code.

Btw it's really meant for personal use coz i want to go afk instead of clicking things.

Basically this is a macro for the game i am playing.

I run the program it will works fine. ^^

So ill go watch or browse the web while letting the program do its job.

The problem is after some time, it will eventually make my keyboard to malfunction.

Like pressing the caps will type small letter, left clicking an icon will drag or right click it and the worst problem is I cannot reboot my PC. Luckily i can still shut it down..

So what is the problem that this code mess up my pc. R_R

note: I do not get this kind of error when using Send command. (But i have to use controlSend coz i want to browse the web at the same time)

Kindly help if there is something wrong with the code.

Thank you.

Edited by Cerro
Link to comment
Share on other sites

I have ABSOLUTLY zero idea if this is anything to do with the problem...

But try changing

ControlSend("game","","",3) to ControlSend("game","","","3")

I would always enclose the string in quotation marks.

Thats all i can think of.

Edited by Steveiwonder

They call me MrRegExpMan

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...