Jump to content
Macro Express Forums

Leaderboard

Popular Content

Showing content with the highest reputation since 06/24/2020 in all areas

  1. In general, you will be better off learning how to use the keyboard to do things in a web page and use TextType to automate. Each control, including links in a webpage should be a tab-stop. All my later macros before I started writing programs were all based on the number of tabs it takes to get to any control in a web page. I have written hundreds of macros to automate web pages and found the overall effort and lines of code about 10% of that trying to use the mouse. Mouse moves is the road less travelled. And, BTW, that means it's the one you don't want to take 🙂 List boxes you can tab
    2 points
  2. Thanks - I have made a feature request.
    1 point
  3. If Variable %all% Contains "%part%" Text Box Display: Yes! Else Text Box Display: No! End If
    1 point
  4. There are many ways to test for evenness / oddness, including this: Variable Set Decimal %Value%: Prompt Variable Modify Decimal: %HalfValue% = %Value% / 2 Variable Modify Decimal %HalfValue%: Remove Integer Portion (%DecimalsOnly%) If Variable %DecimalsOnly% Equals "0" Text Box Display: Even Else Text Box Display: Odd End If
    1 point
  5. I use the .NET WebBrowser control to make my own automated browsers sometimes. This way it's all a model including the rendered DOM which I can interact with programmatically. I figured if I was going to learn a language, which most web automation tools like iMacros need, I woudl just learn how to do it in .NET and make a proper program. Most of the ones I do I use the HTTPWebRequest/Response objects as rendering the document takes time and the text is modified before rendering to 'fix' common problems. So I just grab the raw HTML and get what I need from it using RegEx. I can even trave
    1 point
  6. Hi Alan, My greatest challenge at present is trying to achieve a day’s worth of intended tasks in a 24 hour day! Can hardly believe that I used to manage a commute and work as well as hobbies. Terry
    1 point
  7. Ah, 'tis truly a work of art! Learned some new things. THANKS!!! Reminds me of an old rule I seem to no longer follow: 1. Read up on new software 2. use it for a while 3. go back and see what you forgot/missed. So poking about all the functions would be a good idea! LOVE posting both versions of the macro!!! Nice!! VV
    1 point
  8. You can still use Text File Process to loop through the text. Each line of a text file used by Windows ends with CR followed by LF referred to as CRLF. The Text File Begin/End process reads a line of text up to the CRLF. For convenience in your macro the string read by Text File Process does not include the CRLF. However, in your case, you know that each line originally had the CRLF. So, to determine the number of CRLF's just count the lines. Something like this: Variable Set Integer %N99% to 0 Text File Begin Process: "ansisavedcopy.txt" Variable Modify Integer: Inc
    1 point
  9. Text File Begin Process reads one line at a time, and I believe it strips the CRLF, so your macro will never see the CRLF (as you have found!) I think Samrae is suggesting that you use the command Variable Set String, with option "Set Value from File." That single command loads the ENTIRE file into a text variable, bang, all at once. See illustration below -- my screen shot is ME Pro, but ME3 is similar. When you use this command, the data loaded into the variable retains the CRLF characters. The checkbox to Strip Trailing CR/LF is deceptive -- if you check the box, it strips t
    1 point
  10. This worked for me: The /c parameter tells cmd.exe to close after running. %TEMP% points to the temporary folder. You could also put commands in a batch file c: cd %TEMP% dir > %TEMP%\DirCmd.txt and use the Program Launch command to run the batch file. And then, as rberg said, load the file into a macro via a 'Variable Set String %T1% from File' command or the Text File Begin process command.
    1 point
  11. The only way I have found is to redirect the output to a text file, then read back the text file with the macro script (Text File Begin Process).
    1 point
  12. Well nothing against ISS as it's hard to describe, but importing a text file might sound like CSV data or something. I'll suggest they change the wording. I think "Import Macro Text File" might be better.
    1 point
  13. I think it's just Import > Import Text File ... It's been a decade probably since I've messed with this. BTW you could also create a macro to modify those lines 🙂
    1 point
  14. I think you might be able to Export > Output Macro Information, make changes, and import. I would suggest trying one simple macro to see if it works before trying the big one. And back up all your data. You might also contact ISS support. Also please report the bug to ISS.
    1 point
  15. This sounds like a good Macro Express project. The instructions you will probably need are: Variable Set String %ProgramName% to topmost program name and/or Variable Set String %WindowTitle% to topmost window title
    1 point
  16. Note that you don't have to use parameters. BTW Kevin's example on the support page illustrates that only a space shoudl be between the values. I know this is the same in .NET and other languages and programs. To be clear, if your value was 9 and you used that comma the JScript would receive a parameter "9," (numeral nine and a comma) which can only be used as text. I'm guessing what you did using the Number() function was to create an invalid cast exception. I don't have time to research it now, but what you saw returned "-1.#IND" is an exception code. I found this article for IEEE
    1 point
  17. You have a comma and space in between the parameters when is should only be a space. This works for me.
    1 point
  18. I am speculating that you can't write to the console and get the value back. You need to use the Return function which terminates the script and writes the value to the console. That's what MEP reads in. Post an example of a script. Make is super simple and make sure it only contains commands that are needed to demonstrate the problem.
    1 point
  19. You're right, Terry! Much better. Here's my version, which is functionally identical to yours: Variable Set Integer %x% to 1 Text File Begin Process: C:\Tmp\File Start.txt // This is the text file that contains the index you want to process If Variable %Line[%x%]% Contains "," Variable Set Integer %CommaPosition% to the position of "," in %Line[%x%]% Variable Modify Integer: %CommaPosition% = %CommaPosition% - 1 Variable Modify String: Copy part of text in %Line[%x%]% starting at 1 and %CommaPosition% characters long to %Line[%x%]% Else Variable Set
    1 point
  20. Here's my version, which works OK here. It's heavily commented so hopefully easy to follow, but post if anything unclear. // These variables will be used to end each line of the edited file Variable Set to ASCII Char 13 to %CR% // Set CR Variable Set to ASCII Char 10 to %LF% // Set LF Variable Set String %CRLF% to "%CR%%LF%" // Set combined CRLF // Split each the line into as many parts as the max expected (up to 99). I've used 10. Text File Begin Process: C:\Users\terry\Dropbox\Macro Express (Sundry)\Parsing-1.txt // Test if line is blank. If Variable %tLine% Equals "" // Incl
    1 point
  21. To delete the page numbers, find the position of the first comma and delete everything from there to the end of the line. (The first image below should have % signs around the variable names -- my error, sorry.)
    1 point
  22. I'm constantly fidgeting with my mouse and would soon be staring at a blank screen 😉
    1 point
  23. You're welcome. Perhaps you could add something like this: Variable Modify String: Replace ":\\" in %tFolder% with ":\"
    1 point
  24. I dont' think your file is ASCII, I think it's UTF-8. Those first characters might be the BOM (Byte Order Markers). Look at your file with a hex editor. I use UltraEdit but it's money, so try Notepad++. Don't forget Notepad was upgraded to support Unicode, and by default is saves to UTF-8 now, not ASCII. In Notepad go File > Save As > and look in the lower right and tell me which encoding you have selected. I'm guessing it's UTF-8 with BOM.
    1 point
  25. Be kind. He has been told this three times now across two or three threads. I think he's a newbie trying to get a feel for ME, so best not to scare him away. When I think of the questions I asked when I started using ME, most people must have assumed I was a total moron. Happily most of those posts are lost in the mists of history, but I could come up with more at any time. 🤔
    1 point
  26. I suspect your "Challenges" are really you just getting people to write macros for you. 🙂 Anyway, Tom Sawyer, I wrote a macro for this ages ago and I was just working with Terry on it. I don't like how many people want to dive into the GUI on something like this, it's just a mess. It's much easier to export the macro information to a file and process the text file. Search and report on macro text.mex
    1 point
  27. With MX Pro 6.1.3.1 I'm using Win 10 Version 1909 (OS Build 18363.900) and the Mouse Locator is displaying the colour code OK. MacEdit.exe and MacExp.exe are currently shown as 'Elevated' in Task Mgr. If the issue remains in any application, and after rebooting, I think my next step would be to type SFC /scannow into the Run box or at an elevated command prompt, in case any key DLLs have somehow become corrupted. If your Win 10 version has had a more recent update then perhaps that too is another possible cause. Failing any success I reckon I'd t
    1 point
  28. Simpler than mine. Hardest part of making the macro is looking up the Excel keyboard shortcuts.
    1 point
  29. Go methodically through the commands and use them one by one in very simple macros. Use the Help system. When you do something for learning purposes, make frequent use of Text Box Display so you can see the result. Sounds tedious and probably is, but I should have done it early on. I still occasionally find command options that I have never used. A couple simple examples: // Variable Set String %T1% " ABCD " Variable Set String %T2% " EFGH " Variable Modify String: Append %T2% to %T1% Text Box Display: T1 result is ***%T1%*** Variable Modify String: Trim %T1
    1 point
×
×
  • Create New...