Jump to content
Macro Express Forums

MEX Pro 4 and Q-Dir Hotkey Problems


Recommended Posts

Hey everyone,

 

I'm using Q-Dir as my to go File Explorer programm.

 

For some odd reason MEX cannot send keystrokes/hotkeys to (via Text Type) Q-Dir. They only seem to work sporadically, partially or not at all. I tried to use different scopes (Global, Program/window specific). Even single and basic Hotkeys like CTRL+1 (through 4) are 80% of the time not being registered. I even played around with Keystroke Speeds.

 

Are some programs sometimes just not able to recieve Hotkeys via MEX?

Link to comment
Share on other sites

I don't have many ideas for you or any experience with this program. Some random thoughts. 

Make sure your hotkeys are not reserved in the program in any mode. 

Make sure your window is focused (active). 

Use the debugger. I would specifically look at whether the macro activated. You can tell the by the last run time in Macro Explorer. Just becasue nothing appears to happen doesn't mean the macro didn't activate. 

Try in safe mode. Might be some other utility messing with you. 

Link to comment
Share on other sites

Quote

Are some programs sometimes just not able to recieve Hotkeys via MEX?

 

There are a few applications that MEP can't see. But if your macros work sporadically, that suggests to me that something else is wrong.

 

Add an instruction to your macro to pop a message box as a way to confirm your macros are getting activated.

 

MessageBox: The hotkey was recognized!
	

 

Some programs, especially when running under Windows 10, have trouble keeping focus. Does it help if you click in the Q-Dir window before you activate your hotkey?

Link to comment
Share on other sites

2 hours ago, acantor said:

Add an instruction to your macro to pop a message box as a way to confirm your macros are getting activated.

 


MessageBox: The hotkey was recognized!

You can insert message boxes like this at many critical points in your macro, to determine how far the macro has progressed.  Within the message box you can also display the values of variables, if you are wondering why IF conditions are not being met, and so on.  Once debugging is complete, remove the message box commands -- or, better, just inactivate the commands so you can re-activate them six months from now when something changes and the macro suddenly stops working. 😉

Link to comment
Share on other sites

57 minutes ago, rberq said:

Once debugging is complete, remove the message box commands -- or, better, just inactivate the commands so you can re-activate them six months from now when something changes and the macro suddenly stops working.

 

An accurate description of the life of a person who likes to script macros! :)

Link to comment
Share on other sites

Thanks to everybody so far. The macro gets properly activated. Textboxes get displayed and also i see it in the Macro Explorer in the column "Last Run Time".  I don´t think that the hotkeys are blocked by another program. For example CTRL + 1 works always if pressed manually but only 10% if Text Typed by MEX. 
It´s like this nice alternative to Windows Explorer kind of ignores actions by MEX. 

 

Interestingly other keycommands like CTRL TAB for changing Tabs are recognized 100% of the time. If you browse like i a lot within folders you may check out this 4 Window File Explorer and also this odd problem  😉 . The keycommands CTRL + 1-4 are used for adressing the four Explorerwindows. 

 

http://www.softwareok.com/?seite=Freeware/Q-Dir

Link to comment
Share on other sites

I fear there is not much to see. I also experimented with Delay Times and various keystrokespeeds. I also divided the CTRL + 1 command into three different codelines. No difference!


<TEXT TYPE Action="0" Text="<CTRLD>1<CTRLU>"/>

 

Can anyone reproduce the problem?
 

Link to comment
Share on other sites

I have had macro typing fail intermittently if the keystrokes are entered too fast. 

Most of my macros have this standard command at the beginning:

Keystroke Speed: 30 milliseconds 

That's usually fast enough to keep me from fidgeting, but slow enough so the application is not overwhelmed. 

 

Edit: Oops!  We posted at the same time.  I see you have already tried that.

Link to comment
Share on other sites

So... you manually click inside Q-DIr before you press the hotkey, and sometimes it works, sometimes it doesn't. Any patterns you can discern to the failures, e.g., the hotkey never works the first time you press it, but it always works the second time. If this is the case, not sure what is going on, although it might have to do with a component of Q-Dir stealing focus. 

 

Take a screen shot of Q-Dir window, and post it here!

Link to comment
Share on other sites

Well let´s say i make sure that the Q-Dir Window is active as the macro is scope specific. I can not recognize any pattern. Maybe one could install this tiny tool and try it himself. Just an idea. 😉 You may fall in love with it like i did. 


Q-Dir consist out of 5 areas. On the left the navigation pane. On the right from this four independent folders which even can have different Tabs which i love. CTRL + 1 should always select the first (yellow) folder. 

Another nice feature is that you can define different formats for filetypes. You see the different colours for the filenames in Folderwindow 1 (yellow)

 

 

image.thumb.png.739e2575199ea82827f4aee9083b98b8.png

Link to comment
Share on other sites

18 hours ago, Alexis said:

The macro is triggered by ALT + 1.  

CTRL + 1 is the Output of the macro.

 

It gets activated every time ALT + 1 is pressed. No other macro gets activated.

 

Alexis,

 

More detail needed!

 

Please post your macro and describe the startup state required and what it is supposed to do when you activate it with Alt + 1 if it's not obvious from your commented script.

 

Meanwhile, I've installed the program (64-bit, as Admin),  but using the following minimalist macro, I could not reproduce the issue during a dozen or so runs.


 

// Attempting to reproduce problem described at
     https://pgmacros.invisionzone.com/topic/8883-mex-pro-4-and-q-dir-hotkey-problems/
// Ensure Q-Dir has focus before activating this macro with ALT + 1
Delay: 0.1 seconds
Text Box Display: Temp
Text Type (Simulate Keystrokes): <CONTROL>1
// Now added a long delay (0.5 s) waiting for whatever is supposed to happen after typing CTRL + 1.
Delay: 0.5 seconds // Long delay (0.5 s) waiting for whatever is supposed to happen after typing CTRL + 1.
Text Box Display: Temp





<COMMENT Value="Attempting to reproduce problem described at\r\nhttps://pgmacros.invisionzone.com/topic/8883-mex-pro-4-and-q-dir-hotkey-problems/"/>
<COMMENT Value="Ensure Q-Dir has focus before activating this macro with ALT + 1"/>
<DELAY Flags="\x01" Time="0.1"/>
<TEXT BOX DISPLAY Title="Temp" Content="{\\rtf1\\ansi\\ansicpg1252\\deff0\\deflang2057{\\fonttbl{\\f0\\fnil\\fcharset0 Tahoma;}{\\f1\\fnil Tahoma;}}\r\n\\viewkind4\\uc1\\pard\\f0\\fs20 The macro has been activated by Alt+1\\f1 \r\n\\par }\r\n" Left="Center" Top="Center" Width="278" Height="200" Monitor="0" OnTop="TRUE" Keep_Focus="TRUE" Mode="\x00" Delay="0"/>
<TEXT TYPE Action="0" Text="<CONTROL>1"/>
<COMMENT Value="Now added a long delay (0.5 s) waiting for whatever is supposed to happen after typing CTRL + 1."/>
<DELAY Flags="\x01" Time="0.5" _COMMENT="Long delay (0.5 s) waiting for whatever is supposed to happen after typing CTRL + 1."/>
<TEXT BOX DISPLAY Title="Temp" Content="{\\rtf1\\ansi\\ansicpg1252\\deff0\\deflang2057{\\fonttbl{\\f0\\fnil\\fcharset0 Tahoma;}{\\f1\\fnil Tahoma;}}\r\n\\viewkind4\\uc1\\pard\\f0\\fs20 The macro typed CTRL + 1. Now what?\\f1 \r\n\\par }\r\n" Left="Center" Top="Center" Width="278" Height="200" Monitor="0" OnTop="TRUE" Keep_Focus="TRUE" Mode="\x00" Delay="0"/>

 

 

BTW, I'm always rather careful about using Alt in my activation keys, as I've occasionally had quirky results, particularly under Win 10. And I assume you've tried varying delays after the crucial TextType, and also Wait For Text Playback?

 

To make further progress we need to be singing from exactly the same hymn book, as the devil is usually in the details!

 

Terry

Thursday 1 July 2021, 0907

Link to comment
Share on other sites

And your reply to the rest of my request?

"Please post your macro and describe the startup state required and what it is supposed to do when you activate it with Alt + 1"

 

Also, did you try running mine?

 

EDIT: Meanwhile, as far as I can tell after some trial and error, the application shortcuts CTRL + 1, CTRL + 2, CTRL + 3, and CTRL + 4 appear to successively select each of the four (default) panes. Is that what you want it to do? If so, I was able to reproduce your problem.

Thursday 1 July 2021, 1105

 

Link to comment
Share on other sites

Exactly, CTRL 1 to 4 are activating the four panes. This is what the macro should do. Simply activate Pane 1. I am really happy that you can reproduce the problem because i never experienced that it made any difference if i or MEX is "typing" the keys. I mean thats the beauty about MEX, right? 😃

Your macro made no difference for me. Did it work for you?

Link to comment
Share on other sites

No, mine behaved the same. (Now that I know what it's supposed to do!) There's definitely something strange going on with those hotkeys Ctrl + 1/2/3/4.

 

BTW, I couldn't find them documented? At least, not in the list I've shown below.

 

FWIW I've emailed the author.

 

Q-Dir-HotkeysEtc.jpg

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...