Jump to content
Macro Express Forums

cuppanews

Members
  • Posts

    25
  • Joined

  • Last visited

Everything posted by cuppanews

  1. Thanks. I guess it makes sense that Excel would behave this way. Interesting. Your suggestion of a macro to get around this is good. I'll give it a shot.
  2. Thanks, Randall. Yes, it is a "saved as" CSV file maintained in Excel and not a native Excel spreadsheet.
  3. I'm using a CSV file with the ASCII File Process command for a lookup table. Everything is working really well so far, with one wrinkle. I'm adding new rows to the table in Excel every day, and I often have it open while I'm using the ME macro that processes the data. When the file's open in Excel, the macro fails. I'm puzzled by this. Why is the file not available to other applications while it's being edited? Obviously the saved version on the disk is the only one the macro can see, but if I save after every change in Excel, I'd have thought that ME would be able to use it even though it was still open in Excel. Is that not the case? Thanks.
  4. When I click on, say, the "Macros" menu in the Scripting Editor toolbar, the menu "slides" down into view rather than simply being displayed. It's fun the first time. ;-) I thought it might be an OS thing (although it does't happen in other applications). Sure enough, in Desktop > Appearance > Effects, the first item seems to apply here -- but changing it doesn't have any effect in this case.
  5. Just wanted to mention that I finally got around to this over the past few days. I ended up using a CSV file and the ASCII File Process command -- and it works perfectly! I am SO impressed! The table has only 68 rows right now, but the lookup feels instantaneous. Thanks again for the pointers.
  6. Hi... I want to take a URL and extract the domain name. I've written a macro that does this, but since it's something that's critical to my workflow, I'd like to ask for your thoughts. Is this the best way to do what I want? Are there any obvious flaws in what I've done? The aim here is to get the domain name into T4. The URL is in T2, a variable that is restored when the macro begins. Thanks for your help! M.
  7. In the interests of encouraging remarks in macros, how about making "Insert Remark" a right-click command in the Scripting Editor?
  8. Hi... Is it possible to turn off the animated menus in the Scripting Editor? The "dropdown" effect is giving me motion-sickness. If it isn't, could this be added in some future version? Thanks!
  9. Hi Randall... Thanks for the followup. That link isn't working for me. What is the URL?
  10. Thanks, Kevin! I think I see what you're suggesting, although %T10% would actually be a domain name, something like "www.chinadaily.com". I'll start experimenting with this. I appreciate your help.
  11. Sorry, I guess I didn't express it very clearly. I'm using ME to grab certain information from, let's say, a New York Times article. I get the article title, a short selection of the article text, and the URL. Then I paste that information into a webform, clean it up as needed, and post it on my site. I've got ME macros already written that help with most of this. One of the things I've been adding manually in the webform is a field called "Source". Until now, I've actually been typing out "US-New York Times" or whatever the source is for every item I post. That's the part I'd like to automate. ME already has the URL (as one of the macros I'm already using), so I'd like first to strip it down to domain name only. That I can figure out without help. Here's the part I do need help with: I'd like to search a table for the domain name and have ME return the "long form" of the name. For instance, a simple example of the table might look something like this: domain name long form name ----------- -------------- www.nytimes.com US-New York Times www.globeandmail.com Canada-Globe and Mail www.chinadaily.com China-China Daily ME would search the table for 'www.globeandmail.com' and then type "Canada-Globe and Mail" into my webform. The table would be quite extensive with potentially hundreds of domain name/long form name entries. I'm not knowlegable enough about ME to know exactly how to do the table lookup thing. I'm guessing it could be a CASE statement: if domain name = "www.nytimes.com" then type text "US-New York Times" elseif domain name ="www.globeandmail.com" then type text "Canada-Globe and Mail" elseif domain name ="www.chinadaily.com" then type text "China-China Daily" That's just pseudocode and I haven't tried to implement it yet using ME because my hunch is that it may not be terribly efficient once there are hundreds of CASE statements to evaluate. I'm sure there's a better way of doing this and would welcome any suggestions. Hope I've made it a bit clearer... ;-)
  12. Hi... I've been using Macro Express to automate some of my editing tasks, and I'd like your advice about whether it would be practical to use it in the following way. I'm running a news site. Each day I post links to 60-70 news items originating in any of hundreds of sources. I spend a lot of time entering and re-entering things like "US-New York Times", "China-China Daily", etc. Since there are so many sources, it doesn't make sense to write (or remember) so many individual shortkeys. It's occurred to me that, since I'm already using Macro Express to capture the URL for articles, I could construct a lookup table that would take something like... http://www.abc.net.au/news/newsitems/200507/s1405363.htm ...strip out the domain name... www.abc.net.au ...then look in a table for the "long form" name and type "Australia-ABC" into my edit window. So, my question is this: would Macro Express be able to do something like that reasonably quickly if the lookup table had, say, 300-400 entries? By "reasonably quickly" I mean in about the same time it might take me to type it out manually? Thanks for any thoughts you might like to share.
  13. Ah, OK. I understand now. Thanks, Kevin.
  14. Actually, I'm not quite there yet... ;-) When I use Mouse Click on Control and then specify X/Y coordinates under the Advanced tab, it's not moving the mouse to those coordinates. (The next command is Type Text, and it's doing so wherever the mouse pointer happens to be.) The control I'm using is the top-level browser window -- i.e., I run the Get Control utility,move the mouse pointer up to the window's top border, and then call that C1. Then I use the X/Y coordinates relative to that control's upper-left corner. Am I doing that correctly? On the other hand, this works... Mouse Move Relative to Control %C1%: 98, 352 Mouse Left Button Click Text Type: %T1% I'd rather do the first two commands in a single command (Mouse Click on Control) if I can, and I thought that what you were suggesting would let me do that. Cheers. M.
  15. Joe, I should have thanked you for this sooner. Although I still think that enhancement could be useful, what you pointed out about the X/Y offset is exactly what I needed. Cheers.
  16. It triggered an ZA alert in my system. I wonder if not Macro Express, per se, but the Macro Express editor being set to launch when Windows starts up?
  17. I may be wrong, but I suspect that's Macro Express checking for program updates. That's a pretty common behaviour in other apps as well. If it bothers you, you can just tick "allow" on the Zone Alarm alert box.
  18. I'm just learning about postioning the mouse relative to a control. In doing so, I thought of what I think could be a useful enhancement to the Mouse Location tool. Is there a convenient way of measuring the X and Y offsets from the upper left corner of a control? For instance, if you want to place the cursor in a web form field, how do you calculate the number of pixels to move the mouse relative to the control? Right now, I think all you can do is note the location of the upper left corner using the Mouse Location tool, write this down. Do the same for the new X-Y position. Then subtract the latter from the former. What if you could point to the upper left corner, click and then drag the mouse pointer to the new X-Y position? I'm imagining that as soon as you pressed down on the mouse button, the displayed coordinates would go to zero and then start measuring the distance in pixels until you released the button. What do you think?
  19. Unbelievable. And obvious, I guess! Sigh... Thanks for the followup, Kevin. My macro runs perfectly now...
  20. Please see "Mouse Move doesn't" above...
  21. I'm still trying to get this to work. If you have any ideas why it fails, I'd really like to know! I'm entering text into a web form. My script is actually a bit more complicated than this, but the following reduces the problem to its simplest form. The two screen positions (75, 284 and 75, 555) are fields in the form. The first Mouse Move puts the cursor in the first field. The first Text Type puts "Greetings" into that field. The Wait is there just to rule out the possiblity that I'm rushing the second Mouse Move. (I've also tried Wait for Text Playback and Wait Time Elapse for different durations with the same result in every case.) The second Mouse Move should put the cursor in the second field -- but it doesn't! The second Text Type appends "Hello" to "Greetings" in the first field. Mouse Move Screen 75, 284 Text Type: Greetings Wait Time Elapse: 0 Minutes 2 Seconds Mouse Move Screen 75, 555 Text Type: Hello Any thoughts?
  22. Thank you, Kevin. That's exactly what I was trying to figure out, though I'm embarassed that I didn't see these commands. (As you may have guessed, I'm new to MacroExpress.)
  23. I'm using Firefox and ME. My macro starts on a web page by grabbing the window title, URL, and some highlighted text. Then it switches to another browser tab (Ctrl-1) and pastes the grabbed text into the form. The problem I'm having is that the Mouse Move command seems really erratic. Sometimes it puts the cursor in the right field, sometimes it doesn't. Sometimes it pastes the correct text in the correct field, but then immediately pastes text intended for another field immediately following. As you can see, I've put some Waits into the macro, but they don't seem to be helping. // Get the window title and copy into a string variable. Get Control %C1% (- Mozilla Firefox: ) Variable Get Control Text: %C1% to %T1% // Copy selected text into a string variable. Clipboard Copy Variable Set String %T2% from Clipboard Text Type:<CONTROL>l // Copy the URL into a string variable. Clipboard Copy Variable Set String %T3% from Clipboard // Switch to the Control Panel browser tab. Text Type: <CONTROL>1 Wait For Window Title: "ExpressionEngine" Mouse Move Screen 75, 285 Text Type: %T1% Wait Text Playback Mouse Move Screen 75, 560 Text Type: %T2% Any suggestions? Thanks.
  24. Hi... I want to define some string variables in one macro, and then be able to access them with another macro. Is this possible in an efficient way (i.e., not having to write them to a file)? Thanks.
×
×
  • Create New...