Jump to content
Macro Express Forums

terrypin

Members
  • Posts

    2,230
  • Joined

  • Last visited

  • Days Won

    23

Everything posted by terrypin

  1. What we badly need at this point is an analysis by ME Support about what's going on, and what bugs are identified. Meanwhile I'll be steering well clear of these Date/Time commands. -- Terry, East Grinstead, UK
  2. The result looked a bit better when I got rid of the decimal conversion in macro 2 and instead used this: Variable Restore: Restore All Variables Date/Time: Set %Later% to the current date/time Variable Modify Date/Time: %TimeRun% = %Start% - %Later% Text Box Display: How long? Macro Return <VARIABLE RESTORE Option="\x00"/> <DATE/TIME Flags="\xB0" Date="30/12/1899" Day_Offset="0" Month_Offset="0" Year_Offset="0" Hour_Offset="0" Minute_Offset="0" Second_Offset="0" Left="Center" Top="Center" Monitor="0" Variable="%Later%" IsDateVar="TRUE"/> <VARIABLE MODIFY DATE/TIME DateVar="%TimeRun%" Option="\x01" LeftVar="%Start%" RightVal="%Later%" UseInteger="TRUE" MathOpt="\x00"/> <TEXT BOX DISPLAY Title="How long?" Content="{\\rtf1\\ansi\\ansicpg1252\\deff0\\deflang1033{\\fonttbl{\\f0\\fnil\\fcharset0 Tahoma;}{\\f1\\fnil Tahoma;}}\r\n\\viewkind4\\uc1\\pard\\f0\\fs16 Macro 1 started at\\b Start\\b0 = %Start% (= %StartDec%)\r\n\\par Macro 2 started at \\b Later\\b0 = %Later% (= %LaterDec%)\r\n\\par \r\n\\par So \\b TimeRun\\b0 = %TimeRun%\\f1 \r\n\\par }\r\n" Left="727" Top="609" Width="546" Height="219" Monitor="0" OnTop="FALSE" Keep_Focus="TRUE" Mode="\x00" Delay="0"/> <MACRO RETURN/> Here's the resultant message in How long? Macro 1 started at Start = 28/12/2008 19:29:12 (= 0) Macro 2 started at Later = 28/12/2008 19:30:42 (= 0.0) So TimeRun = 30/12/1899 00:01:30 No idea where ME gets that date from! Can't do more on this right now; please let me know of any conclusions. -- Terry, East Grinstead, UK
  3. I'm pretty sure I've reproduced that problem. My code has some trivial changes so that I could more easily identify what I was doing: First macro: Date/Time: Set %Start% to the current date/time Convert Date/Time to Decimal: %Start% => %StartDec% Variable Save: Save All Variables Text Box Display: Delay Start Delay: 1500 seconds Text Box Close: Delay Start Macro Return <DATE/TIME Flags="\xB0" Date="30/12/1899" Day_Offset="0" Month_Offset="0" Year_Offset="0" Hour_Offset="0" Minute_Offset="0" Second_Offset="0" Left="Center" Top="Center" Monitor="0" Variable="%Start%" IsDateVar="TRUE"/> <CONVERT DATE/TIME TO DECIMAL Source="%Start%" Dest="%StartDec%"/> <VARIABLE SAVE Option="\x00"/> <TEXT BOX DISPLAY Title="Delay Start" Content="{\\rtf1\\ansi\\ansicpg1252\\deff0{\\fonttbl{\\f0\\fnil Tahoma;}{\\f1\\fnil\\fcharset0 Tahoma;}}\r\n\\viewkind4\\uc1\\pard\\lang1033\\f0\\fs16 The delay started at:\r\n\\par %\\f1 Start\\f0 %\r\n\\par }\r\n" Left="820" Top="295" Width="278" Height="200" Monitor="0" OnTop="FALSE" Keep_Focus="TRUE" Mode="\x02" Delay="0"/> <DELAY Flags="\x01" Time="1500"/> <TEXT BOX CLOSE Header="Delay Start"/> <MACRO RETURN/> Second macro: Variable Restore: Restore All Variables Date/Time: Set %Later% to the current date/time Convert Date/Time to Decimal: %Later% => %LaterDec% Variable Modify Decimal: %ResultDec% = %LaterDec% - %StartDec% Convert Decimal to Date/Time: %ResultDec% => %TimeRun% Text Box Display: How long? Macro Return <VARIABLE RESTORE Option="\x00"/> <DATE/TIME Flags="\xB0" Date="30/12/1899" Day_Offset="0" Month_Offset="0" Year_Offset="0" Hour_Offset="0" Minute_Offset="0" Second_Offset="0" Left="Center" Top="Center" Monitor="0" Variable="%Later%" IsDateVar="TRUE"/> <CONVERT DATE/TIME TO DECIMAL Source="%Later%" Dest="%LaterDec%"/> <VARIABLE MODIFY DECIMAL Option="\x01" Destination="%ResultDec%" Value1="%LaterDec%" Value2="%StartDec%"/> <CONVERT DECIMAL TO DATE/TIME Source="%ResultDec%" Dest="%TimeRun%"/> <TEXT BOX DISPLAY Title="How long?" Content="{\\rtf1\\ansi\\ansicpg1252\\deff0\\deflang1033{\\fonttbl{\\f0\\fnil\\fcharset0 Tahoma;}{\\f1\\fnil Tahoma;}}\r\n\\viewkind4\\uc1\\pard\\f0\\fs16 Macro 1 started at\\b Start\\b0 = %Start% (= %StartDec%)\r\n\\par Macro 2 started at \\b Later\\b0 = %Later% (= %LaterDec%)\r\n\\par \r\n\\par So \\b TimeRun\\b0 = %TimeRun%\\f1 \r\n\\par }\r\n" Left="727" Top="609" Width="546" Height="219" Monitor="0" OnTop="FALSE" Keep_Focus="TRUE" Mode="\x00" Delay="0"/> <MACRO RETURN/> The result I see is: -- Terry, East Grinstead, UK
  4. I have a simple macro I've used for years in ME 3 that just launches the Mouse Locator. But in ME Pro it fails, issuing this message: Mouse Locator is Copyright © 2001-2008 Insight Software Solutions, Inc. and is distributed with the Macro Express Software package. License to use this program is only available with a Macro Express license. (I have licenses for both ME 3 and ME Pro.) --------- I've now changed the macro from the single command Program Launch: "MSLocate.exe" to Window Activate: Macro Express Pro - Explorer Text Type (Simulate Keystrokes): <ALT>tl which now seems to work OK, although not so transparently as the simpler original as it activates ME Explorer. -- Terry, East Grinstead, UK
  5. The procedure I'm using for changing the icon of a single macro seems quite long-winded: 1. D-click the macro in ME Explorer 2. L-click the current icon near the top left to display the Select an Icon dialog. By default this always seems to revert to C:\Program Files\Macro Express Pro\macexp.exe, the standard ME icon, even if the previous setting was something else. 3. Click Browse 4. Navigate to appropriate file, e.g. C:\Program Files\Microsoft Office\Office\EXCEL.EXE if I want the familiar Excel icon. 5. Choose the preferred option if several are available and click OK 6. Click Save and Close Is there a smart alternative way to do this for an entire category please? For 50 or so macro icons in a particular category the above will take forever! -- Terry, East Grinstead, UK
  6. The last couple I wrote (which were the first in ME Pro) have index numbers of 493 & 494. Many of that large number are - trivial and should be deleted - bug-ridden and/or not properly finished - disabled - downloaded from various sources because they looked interesting but probably not even tried yet - obscure in function because they were before I developed some 'commenting' discipline But that still leaves a lot that I use frequently. So - as I don't want the complication of trying to run ME 3 and ME Pro together (if that's even possible) - I've just copied the MEX across for the time being. -- Terry, East Grinstead, UK
  7. Steve: I was about to hastily try your code before I leave for a trip but happily see that Joe diagnosed it fast. Joe: Any chance of a new book, or 'Pro Appendix'? See this post
  8. Yes. I just copied my main .MEX file across to here C:\Documents and Settings\All Users\Application Data\Insight Software Solutions\Macro Express Pro\FULL.mex -- Terry, East Grinstead, UK
  9. Installed and registered yesterday and happy that the dozen or so of my existing version 3 macros that I've tried all work fine. Have to leave home for nearly a week so unfortunately no time to play with the new features. Particularly looking forward to learning how to run several macros at once, as well as smartening up my text displays. I hope we can expect an updated version of 'Macro Express Explained'! Hmm - guess I should be posting this in a new forum. Next time... -- Terry, East Grinstead, UK
  10. Thanks all, appreciate those fast replies. Somehow the issue seems to have resolved itself without my making any changes! I've used the macro dozens of times since my post, with consistent success. So I reckon it must have been some sort of rather obscure issue like those Steve suggested. My first thought was a conflict with another of my 'macro' programs, a power utility I use called Stiletto (now obsolete, long since replaced by PowerPro). But I've been using that for many years, well before ME, and can't see any obvious conflict, such as duplication of the hotkey (Ctl+Keypad -). I am using rather a lot of CPU-intensive programs simultaneously, including a video editor, music player, image editor, browser, etc, so there's scope for all sorts of complicated oddities. It's always a bit worrying when you don't know what causes a problem, but I'm happy enough to have it working. -- Terry, East Grinstead, UK
  11. I haven't needed to use the window positioning and sizing commands before, but my first attempt is behaving strangely. The relevant commands I'm using are: Window Resize: Current Win - (Width: 300, Height: 500) Delay 100 Milliseconds Window Reposition: Top Right - Current Win Delay 100 Milliseconds But most times I get 800 x 600. Other times I get 300 x 500 but the window is top left instead of top right. Anyone have any idea what may be going wrong here please? Probably prove to be embarrassingly obvious. -- Terry, East Grinstead, UK
  12. Just duplicate the exact steps you are taking to click it manually. That includes the one or more Text Type: <PAGE DOWN> commands to achieve what you've described, before the mouse commands. This assumes, of course, that the link remains in a consistent location. If it doesn't then you have a more complex macro to write. I'm also assuming that you can't reach the check box by the more obvious method of tabbing. -- Terry, East Grinstead, UK
  13. One other thing you might try in addition to the suggestions from both Steves is Tools > Restore Mouse Hooks That 'Seconds' instead of 'Milliseconds' mistake has caught me out several times! -- Terry, East Grinstead, UK
  14. Those aren't separate programs then, as you said in your original post. They're separate tabs in Firefox - which you didn't mention! Here, I use Ctl+Tab to cycle through FF tabs. -- Terry, East Grinstead, UK
  15. Duh! Thanks Steve, that was the explanation. Seems surprising IMO that forums aren't smart enough to wrap text in these cases. -- Terry, East Grinstead, UK
  16. Steve: To close off this one, can you advise what your setting is please? -- Terry, East Grinstead, UK
  17. I meant to add that you could also, of course, copy these across in groups or even individual cells to separate locations in your accounting application. And assign each to an ME variable if you wish (up to 99), using the familiar Variable Set String %T1% from Clipboard command. Anyone know why the Edit button isn't available on my original post please? Never noticed that before... -- Terry, East Grinstead, UK
  18. I'm still a bit unclear as to what you're trying to do. But if I've understood your last post correctly (in the other long thread about another subject) then you have a worksheet like this: If you just want to copy this to another application then I don't understand why you are trying to associate ME variables with every cell? (Which would in any event limit you to 99.) Why can't you use a simple macro like the following? // TEMP - Cartwheels Query // Go to cell A1 Text Type: <CONTROL>ga1<ENTER> Delay 100 Milliseconds // Select entire column, say 100 cells Text Type: <SHIFT><CONTROL><ARROW DOWN> Delay 100 Milliseconds // Copy these 100 cells to clipboard Text Type: <CONTROL>c Delay 100 Milliseconds // Activate Notepad (like your accounting application) and paste the cells Activate Window: "Untitled - Notepad" Wait For Window Title: "Notepad" Text Type: <CONTROL>v Delay 100 Milliseconds Macro Return <REM2:TEMP - Cartwheels Query><REM2:Go to cell A1><TEXTTYPE:<CONTROL>ga1<ENTER>><MSD:100><REM2:Select entire column, say 100 cells><TEXTTYPE:<SHIFT><CONTROL><ARROW DOWN>><MSD:100><REM2:Copy these 100 cells to clipboard><TEXTTYPE:<CONTROL>c><MSD:100><REM2:Activate Notepad (like your accounting application) and paste the cells ><ACTIVATE2:Untitled - Notepad><WAITWIN2:000010:000000:Notepad><TEXTTYPE:<CONTROL>v><MSD:100><MRETURN> -- Terry, East Grinstead, UK
  19. I've replied in a new thread, Cartwheels Excel processing. The subject of this one no longer seems relevant, and it's already a long and complex one! -- Terry, East Grinstead, UK
  20. Thanks Alan. Out of curiosity, shortly after posting, I did exactly that. It turned out to be less fiddly than I'd expected and allowed me to quickly crop about 200 photos last night. In case any other IrfanView user here has a similar requirement, I've copied my hastily-written code below. Out of habit, I've included generous delays, which may well be redundant, but it's fast enough anyway. <REM2:Crop 3:2 to 4:3 from top left in IrfanView><REM2:Start with image open in IrfanView><REM2:Get depth of original image window; this will be preserved by macro><REM2:Open Properties><TEXTTYPE:i><MSD:100><TEXTTYPE:<TAB><TAB><TAB><TAB><TAB><TAB><TAB><TAB>><MSD:100><TEXTTYPE:<CONTROL>c><MSD:100><TEXTTYPE:<ENTER>><MSD:100><TVAR2:01:03:><REM2:Get the height into T2><TMVAR2:10:02:01:008:004:><REM2:Convert T2 to integer N2><TMVAR2:05:02:02:000:000:><REM2:Open the crop window, which must already be set to 4:3><TEXTTYPE:<SHIFT>c><MSD:100><TEXTTYPE:<TAB><TAB><TAB><TAB><TAB><TAB>><MSD:100><TEXTTYPE:%N2%><MSD:100><TEXTTYPE:<ENTER>><MSD:100><TEXTTYPE:<CONTROL>y><MSD:100><TEXTTYPE:<CONTROL>s><MSD:200><TEXTTYPE:y><MSD:100><MRETURN> -- Terry, East Grinstead, UK
  21. Thanks Steve, appreciate your taking the time to test it. OK, after some further work, I reckon I've found the reason for this major difference. I'm guessing that if you look at Options > Preferences < Delays you'll find your setting is 300 microseconds. That's the default. At some time, for reasons I can't recall, but which were probably concerned with getting more stable operation of some text-typing macros, I must have changed mine to 10,000 microseconds (10 ms). Trying my macro again with various different settings, I get the following results: 300 µS: 4.2 seconds 1,000 µS: 5.2 seconds 10,000 µS: 24 seconds For the time being, I've set it back to the compromise setting of 1,000 µS (1 ms). -- Terry, East Grinstead, UK
  22. Is there a clever way that ME can capture the width and height of an image please? I use IrfanView for cropping, and in the appropriate dialog I need to enter the height in pixels of the original image. ME can 'Set value from current window height', but apparently not from the resolution data. I could do it by the rather fiddly method of opening the Properties of the file in IrfanView and capturing the information there, but I'm wondering if there is a smarter way I've missed please? -- Terry, East Grinstead, UK
  23. Steve, I can't answer your question about the significant difference in text processing speed, but I'm sure one of the ME support guys will be able to do so. I haven't used the clipboard method yet, but will experiment some time soon. BTW, your processing seems much faster than mine. If I've understood you correctly your macro typed 100 lines of "Macro Express Rules", total 1,800 characters. Mine took 24 secs to type 10 lines of 99 (including the variable), just under 1,000 chars. Yours was 5 times faster for about twice the work - a factor of nearly 10 to 1! Could you run my macro as it stands and tell me how long it takes please? This PC is Intel CoreT 2 Quad Core Q9450 (2.66 GHz, 12 MB cache, 1333 MHz); 4 GB DDR2 667 MHz Memory (although, using XP Pro, not all of it gets utilised). -- Terry, East Grinstead, UK
  24. Clever idea, Steve. Could be very be useful in situations when you merely want to read or or browse in another application window. From the following superficial test, any manual activity in that or any other window causes malfunction. I opened a folder of images in a maximised window, with the intention of browsing them. Then I tested the following macro a couple of times. <REM2:Testing whether an ME macro can in effect run in the background, using Steve's neat method><WHIDE:Untitled - Notepad><REP3:01:000001:000001:00010:1:01:><ACTIVATE2:Untitled - Notepad><TEXTTYPE:%N1% This is testing whether an ME macro can in effect run in the background, using Steve's neat method.<ENTER>><ENDREP><WSHOW:Untitled - Notepad><MRETURN> During run #1, I did nothing but look at the screen Result: No problems. (Took about 24 seconds, about 1s more than simply using the Repeat loop directly on a permanently visible Notepad window.) This is what I saw in Notepad when it reappeared: 1 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. 2 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. 3 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. 4 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. 5 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. 6 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. 7 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. 8 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. 9 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. 10 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. --------- During run #2, I scrolled down the screen a few times, to see more images. Result: That was interrupted in various odd ways, with no activity by me. For example, an image opened in my default JPG viewer, IrfanView. This is what I saw in Notepad when it reappeared: 1 This is testing whether an ME macro can in effect run in the background, using Steve's neat metho2 This is testing whether an ME macro can in effect run in the3 This is testing whether an ME macro can in effect run in the background, using4 This is testing whether an ME macro can in effect5 This is testing whether an ME macro can in effect run in the ba6 This is testing whether an ME macro can in effect 8 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. 9 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. 10 This is testing whether an ME macro can in effect run in the background, using Steve's neat method. -- Terry, East Grinstead, UK
  25. 1. In Macro Express, in Scripting Editor, select all your commands, then right-click and choose Copy Command Text 2. In the forum, composing your message, click Insert: CODEBOX from the Quick Access list on the left, then paste in your commands 3. In Macro Express, in Direct Editor, copy all your code to the clipboard 4. In the forum click Insert: CODEBOX again, then paste in your code. -- Terry, East Grinstead, UK
×
×
  • Create New...