Jump to content
Macro Express Forums

rberq

Members
  • Posts

    1,200
  • Joined

  • Last visited

  • Days Won

    61

Everything posted by rberq

  1. David - Any chance of getting hold of the source code for TntMouseDisabler.exe ???? It works great, but I would like to modify it as Tory suggested, so it could run with a command switch rather than a dialog window.
  2. I came across this old thread while looking for something else. I currently have a similar problem with the LASt character of each field being converted to lower case when typed with the TEXT TYPE command. It only affects alphas, not numeric characters, and only on one specific web-based form. So it may be a form problem or an IE problem rather than an ME3 problem. I got around it by appending one space character to the end of each variable before typing it. FWIW Cory's suggestion, to use the clipboard option in the text type command, has been very unreliable for me. Clipboard options in general have been very unreliable -- they will work fine on one computer but not on another, or they work fine now but fail ten minutes from now. Next time Bill Gates drops by, I'll ask him to look into it.
  3. Make very sure the Copy was successful before you do the Delete.
  4. Build the source name in a text variable, for example VARIABLE SET STRING T1 = C:\FOLDER\*.* Same for the destination, for example VARIABLE SET STRING T2 = C:\NEWFOLDER Then use the COPY FILE OR FILES command with %T1% and %T2% as the file values. Alternatively, build a DOS-style COPY, XCOPY, or MOVE command in a text variable, save the variable to a text file with the .BAT extension in its name, then launch the .BAT file with the PROGRAM LAUNCH command.
  5. I looped through the whole hidden list, unhiding and putting on top for two seconds then hiding again. Many were simply a little piece of a title bar. Many others were a title bar with a window frame but nothing in it. Some of the empty windows were transparent, some were opaque. Nothing exciting appeared except the laptop Power Meter.
  6. Schedule a macro to run every three seconds or so. The only commands in the macro are SET MOUSE SPEED 30 MS MOUSE LEFT CLICK MOUSE LEFT CLICK MOUSE LEFT CLICK
  7. Just for fun, how about using the ME command to UNHIDE a few of them?
  8. Win XP and ME3, right after reboot, "nothing" running: 34 hidden windows. (repeat with hidden windows). Most of them are more or less identifiable.
  9. Try adding a Text Box Display right after IF CONTROL FOCUSED, to verify that ME in fact recognizes when it gains focus. I tried your logic with a button in the Windows Calculator application, and a button in the file-save box of Notepad. I had no problem with IF CONTROL FOCUSED. However, WAIT FOR INVISIBLE worked with Notepad but not with Calculator. WAIT FOR LOSE FOCUS worked on both. Can you perhaps use that instead?
  10. I'm using ME3, trying for the first time to use IF MOUSE CURSOR. My macro moves the mouse across the screen, waiting for the icon to change from an arrow to the pointing hand when it reaches a clickable web address. When I code IF MOUSE CURSOR NOT ARROW, the change is detected. However, if I code IF MOUSE CURSOR IS POINTING HAND, I never get a hit even though I can see the icon change. Is there some setting in Windows Control Panel that might fix this, or have some of you had trouble with the mouse cursor in ME3 as well as MEP? Edit: Never mind! I changed it to IF MOUSE CURSOR IS INTERNET NAVIGATE and now it's happy.
  11. Great outside-the-box thinking, Cory. Now I see why we keep you around ....
  12. Or, arrow down and TEXTTYPE the F2 key, which does the same as ALT-fm.
  13. I have found it is not good to be overly precise with pixels. You might capture the pixel string today, and again tomorrow, and find tiny differences between them, or tiny differences from one computer to the next, which renders an exact comparison useless (even if we could figure out how to do it). IF you know approximately where the control is, here's something I have found to work on a number of windows: Set x-y coordinates in the "background" area of the window, above where the control is to be found (or to its right, or left, or below it). Find pixel color at the beginning point. Step one pixel position at a time toward the control. At each step, check whether pixel color has changed (indicating the boundary of the control). Step the coordinates by 5 or 10 or whatever to put you well within the control, rather than at its boundary. Click on it, or capture it, or whatever you want to do. I don't know if this helps you or not. Maybe you could provide a few more details of what type of control you are trying to locate, what application the window is for, and so on ....
  14. This is what I mean by getting rid of the REPEAT and all the references to %N2%: // ***OPENING MONARCH**** Variable Set Integer %N2% to 1 Program Launch: "Monarch.exe" Wait Time Delay 3 Seconds Text Type: <ALT>f Wait Time Delay 1 Seconds Text Type: R Wait Time Delay 1 Seconds // If File Exists "VCRR" ~~~~~ End If // If File Exists "VCCBK" ~~~~~ End If // If File Exists "VCREP" ~~~~~ End If // If File Exists "MCRR" ~~~~~ End If // Wait Time Delay 1 Seconds Text Type: <BACKSPACE> Wait Time Delay 1 Seconds // If File Exists "MCCBK" ~~~~~ End If // If File Exists "MCREP" ~~~~~ End If
  15. I think you mean Variable N2; there is no reference to N1 in the macro. I put a text box display of N2 right after the REPEAT UNTIL statement, and it is incrementing properly for me. The REPEAT structure and the use of N2 seem to serve no useful function, since you execute a separate block of code each time through the REPEAT loop. Why not get rid of the REPEAT and all checking and incrementing of N2, and simply run the blocks of code for each IF FILE EXISTS one after the other?
  16. I don't think ME stores any indicator that you can access. However, as Phonemes says, why not make your own indicator? Do a simple test, before the ACTIVATE OR LAUNCH, where you set a switch to be checked at the end of your macro. IF PROGRAM 'NOTEPAD' RUNNING VARIABLE SET T99 = 1 END IF ACTIVATE OR LAUNCH OTHER MACRO STUFF IF T99 <> 1 TERMINATE PROCESS 'NOTEPAD' END IF If there are multiple instances of NOTEPAD running, TERMiNATE closes one instance -- in my testing, it seems to close the one that was chronologically the first one started. But you would probably want to test that further before assuming that it is so. The Help screens did not say.
  17. I don't think so, with ME3. You can write a macro with a bunch of disables or enables in it, and run that. Take a look at ME Pro. It has some added features, but I don't know if what you want is included.
  18. Another method I have used is, click somewhere on the window (sometimes necessary with web pages), then do CTRL-a to highlight all the text, copy to clipboard, then "IF CLIPBOARD CONTAINS" some text that is unique to one window or the other. Click again on the window to un-highlight. The drawback to this, compared to checking various pixel positions, is that it's visible and potentially disruptive to the user.
  19. The learn mode is an excellent idea, if each window has unique characteristics. Write a little macro that checks pixel color at the mouse location, and appends the coordinates and color to a text file. [use a hotkey combination to run the recording macro, because if you actually click the mouse (rather than just position it) the application is likely to do something based on your click.] You can save the pixel color at one point or many points, in a separate file for each window. Then, when another macro wants to distinguish one window from the other, it just reads back each file of window coordinates, checks the pixel colors, and if they match perfectly you have identified the window. I have a whole application based on this method, because the application is web-based and seven different windows all have the same title.
  20. I have bought hardware from IBM with booklet explaining, in 68 languages, that one should be careful when plugging in the power cord. Ah, the subtleties of Englisch. "is much improved" and "has much improved" are both equally correct. "has" denotes a period of time during which something occurred. "is" refers to the present condition of something without really specifying when it reached that condition. Another way of looking at it is, the phrase "has improved" is a verb form, like saying "I grew taller". The phrase "is improved" uses improved as an adjective, for example "I am taller than I was last year". Don't worry. Your English is excellent.
  21. Wow! You do extremely well for only 5 years of school study! I studied French for 3 years, and I could not order a hamburger in a French McDonald's unless I could point with my finger.
  22. That is not exactly what I said. I said analyze the whole screen both before and after the "find". But here is a variation on your method of estimating the area where the text will be: Treat the whole window as the "estimated area". First, in order not to have such a large area for pixel checking, use ME commands to re-size the window to be very small, maybe a quarter or a tenth of the screen size. Making it full-screen width, but one-tenth screen height, would be a good starting point for testing. Then when you do the "find" most browsers and other applications will bring found data to within the display window, giving you a much smaller area to search compared to the full screen. No guarantee that it will work, but it's worth a try.
  23. The only way I can think to do it, is scan and record pixel colors on the screen before the "find". Then scan again after the find, and where pixel color has changed due to highlighting is where you want to move the mouse to. I fear this would be unacceptably slow with Macro Express, if you scan every pixel. However, if you know that a highlighted word will cover a minimum of, say, 20 pixels high by 40 pixels wide, then you could scan in increments of maybe 10 by 20 pixels and reduce the time considerably. (I'm just making very rough estimates here.) It still might be unacceptably slow. The only way to find out would be to write the logic and try it. Shouldn't be too hard to code it.
  24. Probably. It would depend exactly what you are trying to do. It's easy to activate a macro with a key combination and have it type some characters. You could possibly activate a macro based on the title of a pop-up window that is asking for a password, and have the macro type some characters. It gets more complicated if the macro has to figure out what excel document you are trying to access, and type a different password for each document. Can you be more specific as to what you are trying to accomplish?
×
×
  • Create New...