Jump to content
Macro Express Forums

Leaderboard


Popular Content

Showing content with the highest reputation since 07/21/2019 in all areas

  1. 1 point
    Alan, I got same behaviour on the couple of tests I had time for (Firefox and a folder). Strange. Speculative, but may be related to the other mouse cursor issue we were discussing? -------------------- EDIT at 08:40 Scrub that speculation! It's because the macro logic is wrong! The following does the job: Variable Set Integer %x%: Set to the Current Window's Width Mouse Move: %x%, 0 Relative to Current Window Mouse Move: -10, 10 Relative to Last Position // Nudge the mouse pointer a little so that it is visible in maximized windows <VARIABLE SET INTEGER Option="\x0A" Destination="%x%"/> <MOUSE MOVE Option="\x02" X="%x%" Y="0" _PROMPT="0x000A"/> <MOUSE MOVE Option="\x03" X="-10" Y="10" _PROMPT="0x000A" _COMMENT="Nudge the mouse pointer a little so that it is visible in maximized windows"/>
  2. 1 point
    Are you sure you don't mean Alt-Enter?
  3. 1 point
    Hard to advise without seeing an example macro. For instance, are you activating it when a window is opened with that title? Or when it gains focus as @acantor assumes? And must it be an exact title or a partial one? What operations is it performing after starting? If for instance it's using a Text Box Display (TBD) to give you a message then as soon as you close that TBD it will probably regain focus and start the macro again. However, I've found that MEP sometimes does not respond reliably to window title commands. Timing or other obscure conflicts with the OS may be the cause. In which case other 'recognition' methods may be needed. Could you share a very simple macro that consistently exhibits 'activating over and over'? (Ask if you don't know how to do that.)
  4. 1 point
    Try changing the activation from "Window Gains Focus" to "Window is Opened." That change will hopefully cause the macro to activate only when the window first opens, rather than every time the window receives focus.
  5. 1 point
    One frustration – not really the fault of ME – is the unpredictable time it takes for a copy-to-clipboard command to finish. The ME solution is to set a clipboard delay in “Preferences”, presumably allowing the command to finish. A short delay – even a long delay – always winds up being too short in rare instances; and a long delay wastes a lot of user time. My most useful macro, below, is called by other macros wherever an inline Clipboard Copy would otherwise be used. In ME “Preferences” the clipboard delay is specified as zero. The macro finishes almost instantaneously when the clipboard copy is fast; and waits patiently for over a second when the clipboard copy is slow. My concern when writing the macro was, that Windows would return a non-null but still incomplete clipboard value, so the macro would return to caller with only part of the intended data. In practice that has never happened, and I have been using it exclusively for years with never a problem. // // Set clipboard to nulls -- check to make sure it happens Clipboard Empty Repeat Start (Repeat 10000 times) If Clipboard Text Equals "" Repeat Exit Else End If Repeat End // Copy to clipboard (CTRL-c) Clipboard Copy // Loop until clipboard is non-null, that is, copy to clipboard has completed. Since the value // to be copied may in fact BE null, we limit the loop to a nominal 1 second, then quit, leaving it null. // (Due to overhead, the actual loop time will be more like 2 seconds than 1.) Repeat Start (Repeat 100 times) Delay 10 Milliseconds If Clipboard Text Equals "" Else Repeat Exit End If Repeat End // Return to caller Macro Return //
  6. 1 point
    That's a difficult one! No single macro would warrant the title of 'my best' and if I compiled a short list of 'most useful' from the couple of thousand I've written it would cover a wide spectrum. Used up to scores of times a day - Sizing and positioning windows (mainly File Explorer folder) - Opening frequently used folders - Typing frequently used text with shortkeys (file and folder paths, signatures, email addresses, my name and address, phone numbers, regular phrases like 'Best wishes', etc) - Typing date & time with shortkey '=dt' Wednesday 7 August 2019, 1402 - When saving a series of files (such as when browsing images or text etc that I need for videos), a click close to the right of 'Save As...' (or variations) saves it as xyz-05 if the previous was xyz-04 - In all my applications, middle clicking its title to display a menu of macros, sometimes via subfolders - When creating a Text Box Display command, generate 'VariableName = ' to the left of '%VariableName%' with a single click -Etc Infrequently used but invaluable - During my frequent work in Google Earth, Google Maps, Memory-Map, etc: finding/copying/moving places and tracks between them; changing properties of multiple tracks, etc - On average once or twice a week, but many more directly after a walking holiday: from the GPX file of a walk recorded on my iPhone, automatically creating an Excel spreadsheet like that I showed in the recent thread about VBA, plus a profile like this: https://www.dropbox.com/s/63dwbplk410mj80/20190709Falmouth-Portscatho-r483-m6.7-PS.jpg?raw=1 (That's one of my most complex macros, calling a dozen submacros, some of which use VBA and some use Python scripts I've written in PaintShop Pro. I'd say it's probably the one I'm most proud of.) - One of Cory's, with only minor adaptation by me: 'Search and report on macro text'. - Etc -------------------- I'd like to have used the 'Last run time' column to give a more objective reply on the first category, but (a) It doesn't include submacros (b) It gets destroyed when a new version is installed
  7. 1 point
    I have written some very complex and powerful macros. A hospital back east had banks of computers running a macro I wrote around the clock for years. But the two that I have gotten the most use out of are simple. The first one simply types a date stamp. I use it in file names, notes on task, and dozens of other places. I'm amused at how often that's useful The second is a task tracking number. I type "TTN..." and it looks up the last number, increments it, and types out something like "TTN4521". I create tasks in Outlook with this in the subject, tag emails, time logs, task folders, and many other things. Later it's easy to find all relevant correspondence, file, whatever. And I have another "TTNR" which re-types the last number. Funny that I've written so many complex and powerful macros, and yet this is what I use most. Of course when professionally developing macros, one doesn't use those oneself. On a related note, I don't write as many macros as I did. I have been programming now for years and when it comes to automating most things, a proper program is better. Like web scraping. MEP is just not suited for that kind of stuff. But what MEP is great at is things like this. The little macros that save seconds a hundred times a day. Also things that are semi-automatic. Like a macro to file a PDF file from a scan where the user has to answer some questions and the macro blasts though all the menus and dialogs. One just can't beat it for things like that.
  8. 1 point
    To run any macro posted to you in the form that I did, you you can either: 1. Type the commands into a new macro of your own, but changing anything that needs it. In this case you don’t have a folder called "c:\users\Terry\Test" so create one of your own and enter that instead. 2. Copy the code and paste it into a new macro, then make the same change.
  9. 1 point
    One thing to try: From the list of macros in the macro explorer, right-click on it and choose 'copy.' You'll have to give it a new name and trigger, but the code will all be the same.
×
×
  • Create New...