Jump to content
Macro Express Forums

All Activity

This stream auto-updates     

  1. Yesterday
  2. Announcement: Macro Express v 3.11a

    As rberg said, download the latest version of Macro Express here: macros.com/download.htm Here is our upgrade policy: macros.com/upgrade.htm
  3. Last week
  4. Announcement: Macro Express v 3.11a

    www.macros.com/download.htm You should be able to apply the same license code you used for your initial installation and for your last upgrade.
  5. Announcement: Macro Express v 3.11a

    i Kevin! I've been a happy Macro Express user for many years. My latest upgrade was to v3.10b. Is 3.11 a free update? If so can you provide a link to the download. I've been unable to find the path - Happy New Year, and thanks for the help - Bob
  6. Saving to Excel in background

    Pleased to report a successful solution. I chose the text file method for my MX Pro macro, which was tedious but simple to write. Here's the first part: // Set up ******* Variable Set to ASCII Char 13 to %CR% Variable Set to ASCII Char 10 to %LF% Variable Set to ASCII Char 9 to %TAB% Variable Set String %CRLF% to "%CR%%LF%" // Enable next command only when using a pre-prepared test set **************************************************** Variable Restore: Restore All Variables Text Box Display: Variables reported in 'GPX track - Display captured variables' // Get all variables into a text file as a list ********************************* // GPX filename =tTrackname.gpx Variable Modify String %tAllVariables%: Append Text (GPX file name) Variable Modify String %tAllVariables%: Append Text String Variable (%TAB%) Variable Modify String %tAllVariables%: Append Text String Variable (%tTrackname%) Variable Modify String %tAllVariables%: Append Text (.gpx) Variable Modify String %tAllVariables%: Append Text String Variable (%CRLF%) // tReportDate Variable Modify String %tAllVariables%: Append Text (ReportDate) Variable Modify String %tAllVariables%: Append Text String Variable (%TAB%) Variable Modify String %tAllVariables%: Append Text String Variable (%tReportDate%) Variable Modify String %tAllVariables%: Append Text String Variable (%CRLF%) // Track Descr'n = tTrackDescr Variable Modify String %tAllVariables%: Append Text (Track Descr'n) Variable Modify String %tAllVariables%: Append Text String Variable (%TAB%) Variable Modify String %tAllVariables%: Append Text String Variable (%tTrackDescr%) Variable Modify String %tAllVariables%: Append Text String Variable (%CRLF%) . . . // Profile Link GE (DEM) = tProfileLinkGE(DEM) Variable Modify String %tAllVariables%: Append Text (Profile Link GE(DEM)) Variable Modify String %tAllVariables%: Append Text String Variable (%TAB%) Variable Modify String %tAllVariables%: Append Text String Variable (%tProfileLinkGE(DEM)%) Variable Modify String %tAllVariables%: Append Text String Variable (%CRLF%) // Now save that list as a text file ************************************ Variable Modify String: Save %tAllVariables% to "C:\Users\terry\Dropbox\Excel+VBA (Sundry)\TEMP-VariableList.txt" // The reason for postponing the remaining entries for MM and Best Estimates (and any others) is to minimuse risk of havng to start afresh in the event of some problem or crash during those final stages. // Now switch to Excel and paste the entries from the list ********************************************** Macro Run: Open TrackData-New.xlsm Macro Run: VBA - ImportFile_1 The VBA macro proved easier than I'd thought. Tedious (50 copy/pastes, mainly to non-contiguous cells) but worthwhile as running it took 5 secs, compared with about 60 for the previous MX macro.
  7. Saving to Excel in background

    Automated. The macro scans the clipboard text for identifiers, then finds a value after the third subsequent dollar sign for each identifier.
  8. Saving to Excel in background

    Thanks rberg. Is the assigning to variables, from the screen copy, manual or automated?
  9. Saving to Excel in background

    I have a macro to do a similar thing, but on a smaller scale -- a dozen or so values rather than your 50. Rather than use a text file, I copy the whole screen to the clipboard, extract the fields I want into ME variables, switch once to Excel, Ctrl-Home to the first cell, and type arrow keys to get to the desired cells to type the variables. It is very fast and reliable, but it doesn't do Excel in the background like you would prefer. The logic to make sure there are no missing fields is in the extraction macro.
  10. Saving to Excel in background

    Thanks Alan, I've been exploring that, and have posted to the Excel forum. In those few cases where I've been able to use a VBA macro, it's been enormously faster, so I certainly have motivation. But my preferred approach of pasting directly after every capture is proving difficult to implement with a VBA macro. Every paste goes to a unique cell. It also means 50 switches to and from my Excel workbook. So I think I'm going to focus on the text file method. Wish I could put my current project on hold while I move up the VBA learning curve a bit, instead of being stuck mainly in copy/paste plus minor edits mode!
  11. Saving to Excel in background

    A VBA macro might be the ticket. Try recording the procedure using Excel's macro recorder, and then modify the code to create a more general solution. The folks on various Excel VBA help forums might be able to provide assistance.
  12. Saving to Excel in background

    I've ruled out using MX Pro Controls in Excel (Excel 365 here). I've tested using Get Control and Capture Control. The simple test below is typical. No matter which option of Capture Control I choose, it captures only the name of the workbook. Ignores screen co-ordinates whether specified or using 'Beneath mouse', sheet - everything. No way to capture cell (address or content), worksheet name, etc. // Testing Controls in Excel. Capture Control from Specific Coordinates into %cCellA1% // Trackdate Get Control Text from %cCellA1% into %tCell% Text Box Display: // Display cCellA1 and tCell My grunt method below works reliably, but at about 1 sec per cell it's glacially slow. // This pastes a variable (here a fixed string) into cell B1 of blank spreadsheet ********************************************** Text Type (Simulate Keystrokes): <ALT>eg // Open the 'Go To' dialog Text Type (Simulate Keystrokes): b1 // Select target cell Text Type (Simulate Keystrokes): <ENTER> // Confirm Text Type (Use Clipboard and Paste Text): abc defgh ijkl mnopqrst uvwxyz // Paste the clipboard contents Text Type (Simulate Keystrokes): <ENTER> // Apply
  13. Saving to Excel in background

    Thanks Cory, appreciate the kind offer. But I already have a longish list of 'Must learn..' topics on the back burner and can't risk adding .NET to it!
  14. Saving to Excel in background

    I don't have an answer. I started using simple .NET application using Interop for this a long time ago and have never looked back. So simple and efficient. If you would like me to make you a simple application like this and show you how it works, I can. But one thing I was thinking about but have never tried is simply linking to a CSV in Excel? Excel is great at linking to databases and all sorts of data sources. They simply refresh their data on command or on schedule. It might not work for what you need however.
  15. Before I get going seriously on this macro I'd appreciate knowing whether - it's impossible? - It's possibe and someone's already done something similar and happy to share code? I have a macro (with several submacros) working in a couple of mapping applications, operating on walks/hikes/trips etc, call them all 'tracks'. For each track I capture about 50 text strings. I could get each to the clipboard immediately after they are captured. Or I could generate a list as I proceed and save a file (TXT or CSV) at the end of all the captures. I want to get them all into 50 specified (not consecutive) cells of a single Excel worksheet. If I choose the 'copy one at a time' method, I'd have to repeatedly return to my macro after pasting each one into Excel. If instead I go for the 'accumulate in text file' method I'd have to switch to Excel, import the text file and paste each of its 50 entries into their corresponding cells. My preference is for the first method. 1. it's less extra code to add to my macro and 2. if I make a mistake in the capturing at some point, I don't lose everything. But is that possible with Excel staying in the background, not flashing up 50 times, using Controls? Terry, East Grinstead, UK
  16. Thanks acantor; makes sense as something to try! However, even at the slowest repeat rate it didn't have any on the problem. I'm settling on the idea that this is a problem with how Postbox works with the Windows API.
  17. Good thinking! Though I can't quite "logic" out why that works. I would have guessed Repeat Delay would make the difference, rather than Rate. Now that you have me thinking about it, I lengthened my Repeat Delay, because maybe the short delay accounts for some of the the double-character errors I have been making lately with my typing. I was blaming sluggish fingers or sticking keys, and it never occurred to me to blame the keyboard settings. (Sorry, this has nothing to do with ME macros, I'm just happy to get rid offff thoose exxtra chaaraactters I have beenn typping.)
  18. This approach solved a dropped character problem when I was creating ME macros for an Java application: In the Control Panel, go to Keyboard Properties, and reduce the repeat rate. Setting the value to 25% or 30% was enough to prevent characters from dropping when I sent input via Text Type.
  19. Earlier
  20. Interestingly, I had already tried a keystroke speed of 3000 ms.! Didn't help...but thanks for trying to help me out.
  21. Just as an experiment, try "Keystroke Speed: 1000 Milliseconds". It will be excruciatingly slow, but if it works then you know timing is the issue and you can experiment with other speeds. Or maybe do the opposite of my second suggestion: use the Text Type option that pastes from clipboard. Though that option has always been troublesome for me.
  22. Thanks for ideas....tried them all; no change. However, if I disabled Use high speed timer in millisecond delays, the problem improved for characters that were dropped in the middle of a word or group of lines. For instance: "ManagePLUS" was "anageLUS" but after disabling the high speed timer is "anagePLUS" (The "P" is now present.) This was not a problem in the old Postbox version, and is not a problem in other applications. Likely due to Postbox using a significantly cross-platform code base, which somehow is not fully compatible with the keystroke sending facilities of Windows. ...if you have any other ideas, I'd be glad to hear them. Thank again.
  23. I have seen this behavior on rare occasions, but don't recall that I ever really figured it out. A few things to try: 1) Set keystroke speed to a reasonable value -- I generally use 30ms, but that's just an arbitrary value. 2) If you are using the Text Type option that pastes from the clipboard, don't use it. 3) Try typing a few blanks, then type the same number of backspaces to get back to the beginning of the field, then type the real data. That has worked for me sometimes. I know, it's sort of a Mickey Mouse fix, but if it works ...
  24. I updated my Postbox email client to version 5.0.22 two days ago...then executing Text Type macros from my old Macro Express 3.9a dropped characters when creating new emails in Postbox. So I updated Macro Express to the current, but it still drops characters--always the same characters for any given macro--in Postbox. For instance "screenshot" is always "creenshot". Is there a setting, or other, in Macro Express which might have bearing on this problem?
  25. PDF still open

    Try the Wait for File to be Ready command. If Folder Exists: "\\SCANSERVERHOST\PPLImageDepot\Processing Temp" Repeat with Folder C:\Scans // PLow thru the folder Clear Variables Variable Set From File path // Get teh file extension Variable Set From File: Set to the Size of a File (C:\Scans\%File%) If File Exists: "C:\Scans\%File%" If Variable %Size% Is Greater Than "0" Wait for File to be Ready: C:\Scans\%File% Copy File/Files: "C:\Scans\%File%" to "c:\Scans Sav" Move File/Files: "C:\Scans\%File%" to "\\SCANSERVERHOST\PPLImageDepot\Processing Temp\%File%" On Error Catch Error: File could not be located Macro Stop End Catch Error End Error End If End If End Repeat End If
  26. Thanks for the clarification. I was far more concerned about an IF statement not working, than about the cursor business.
  27. I re-did the IF cursor arrow ELSE END IF statements and it is working now as far as writing one of the log records. I may have forgotten to update the error log file for that command from the network share to my local folder for testing. But the results are now just inconsistent and so unreliable - sometimes it indicates it sees an arrow, other times it does not. Checking for a cursor change still seems to be the most reliable option.
  28. Thanks for the feedback. It's really strange that the "IF ... ELSE" in your original example didn't write anything to the log.
  1. Load more activity