Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Pssible Solution
#1
I have several macros that I only want to execute if a certain keyboard is connected. That keyboard's id is put into a macro via the below code. When those macros are triggered, they pull all the ids of the connected devices and search for the main keyboard id, if it is not found, the macro ends.

could my code be the problem here? Because when i ran it this morning, it said this. And it seems that the 2ndy keyboard is almost always involved in the crashes...

Quote:RIDATA: previous declaration is different. Change?
Warning: if you change declaration while other functions are compiled using old declaration, they may become invalid and cause exceptions or even data corruption. Solution - restart QM.

Macro
Code:
Copy      Help
;This will set the main keyboard variable and the macro that holds the info
type RIDATA !k[4] !m[4] kt[4] mt[4] !kworking !mworking !vk !mb keyboard_id mouse_id
type RIDATAR flags k[4] m[4]
RIDATA+ g_ri
_s=g_ri.keyboard_id
_s.setmacro("Main Keyboard Value")
An old blog on QM coding and automation.

The Macro Hook


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)