Jump to content
Macro Express Forums

Modified date/time - bug


Recommended Posts

If I open a macro in Script Editor for whatever reason, then close it with no change, the Modified column in Explorer changes to the current date/time.

 

IMO that column is therefore of little if any practical value.

 

--

Terry, East Grinstead, UK

Link to comment
Share on other sites

If I open a macro in Script Editor for whatever reason, then close it with no change, the Modified column in Explorer changes to the current date/time.

 

IMO that column is therefore of little if any practical value.

 

I cannot replicate this. If I close the Script Editor without saving a macro, the "Modified" column is exactly as it was before I opened the macro for editing.

Link to comment
Share on other sites

I cannot replicate this. If I close the Script Editor without saving a macro, the "Modified" column is exactly as it was before I opened the macro for editing.

 

Thanks both.

 

I see what's happening. I'm using 'Save and Close' to remove the macro from Script Editor, so the Save changes the Modified Date/Time, even though there's been no modification. This is out of habit, as there's no single button to merely Close that tab. I'll have to get into the habit of either using two mouse clicks to do so, or releasing the mouse and typing Ctl+F4. Or the slower third alternative of locating the tiny X on the tab and clicking that.

 

I made a feature request over a year ago for a prominent Close button alongside the Save and Close and Save buttons.

 

--

Terry, East Grinstead, UK

Link to comment
Share on other sites

I see what's happening. I'm using 'Save and Close' to remove the macro from Script Editor, so the Save changes the Modified Date/Time, even though there's been no modification. This is out of habit, as there's no single button to merely Close that tab. I'll have to get into the habit of either using two mouse clicks to do so, or releasing the mouse and typing Ctl+F4. Or the slower third alternative of locating the tiny X on the tab and clicking that.

 

I made a feature request over a year ago for a prominent Close button alongside the Save and Close and Save buttons.

 

You can also use the standard Windows "close" hotkey, Alt + F4 to exit the Scripting Editor. If you have modified the script, you will be prompted to save (or not).

 

Or, do what I do. Write an application-specific script for the Scripting Editor. I use Esc to activate it, but you can choose anything you want. The script consists of one line:

 

Text Type (Simulate Keystrokes): <ALT>sc

 

This is the equivalent of choosing "Close" from the "Script" menu.

 

I write a lot of macros triggered by ESC that close windows. I currently have 18 of them!

Link to comment
Share on other sites

You can also use the standard Windows "close" hotkey, Alt + F4 to exit the Scripting Editor. If you have modified the script, you will be prompted to save (or not).

 

Or, do what I do. Write an application-specific script for the Scripting Editor. I use Esc to activate it, but you can choose anything you want. The script consists of one line:

 

Text Type (Simulate Keystrokes): <ALT>sc

 

This is the equivalent of choosing "Close" from the "Script" menu.

 

I write a lot of macros triggered by ESC that close windows. I currently have 18 of them!

 

Thanks. I've never assigned ESC as an activation, because of its wide usage, but maybe I've been too cautious.

 

In this particular case, of course, it's Close Current Tab I want. (I find closing the entire Script Editor window is easy enough using the standard method of clicking the X icon, top right). So I assigned Esc to a macro 'Close this macro in Script Editor', which is scoped to a window partially matching 'Macro Express Pro - Script Editor ['

 

Keystroke Speed: 10 milliseconds

Text Type (Simulate Keystrokes): <CONTROL>F4

But it ran wild, running at least one other macro and other odd things!

 

Eventually I established that it was somehow activating a global macro with hotkey activation <Ctl + Shift + f> . (I normally use that only when I'm viewing the current wallpaper on my desktop, as there appears to be no way of scoping ME Pro to the desktop). But as for why, I've so far not a clue.

 

Anyway, I eliminated that issue by adding 'Macro Express Pro - Script Editor [' to the Global Except scope of that other macro.

 

But that leaves other erratic behaviour, which itself seems to vary. Sometimes the character 'f' is being added as a prefix to the name of the macro I am trying to close, and it then sits there waiting to be saved with that new name. At other times the number '4' is being added in the box at the bottom of the Command List (never used it, but apears to be a search box of some sort). And on yet other occasions it runs the macro (I'm assuming it's this one!) but apart from a brief ripple of my XP Pro taskbar, nothing happens. The one thing it doesn't do is close that tab!

 

Same result with activation hotkeys other than Esc.

 

Vaguely reminiscent of problems I've reported before over the last year or so about Script Editor behaviour, but I can't pin it down.

 

--

Terry, East Grinstead, UK

Link to comment
Share on other sites

hi Terry,

 

I see the problem.

 

You want this:

 

Text Type (Simulate Keystrokes): <CONTROL><F4>

 

Not this:

 

Text Type (Simulate Keystrokes): <CONTROL>F4

 

Thanks Alan - well spotted! I've no idea how that came about. I'm positive I used a button as usual to add it. But in future I'll do an eyeball check on the result. ;)

 

Works fine now. Pleasingly intuitive to use Esc to do the close.

 

--

Terry, East Grinstead, UK

Link to comment
Share on other sites

Works fine now. Pleasingly intuitive to use Esc to do the close.

 

Agreed... it's intuitive, at least for people who became acclimatized to using Esc to exit screens in earlier versions of Windows, and in DOS.

 

I have an window-specific macro that sends <Alt><F4> when the title contains "Help". It allows me to close any Help screen by pressing Esc, just the way it used to work in Windows 95 and 98.

 

(There is, however, a tiny side effect. If a document or file has "help" in its name, pressing Esc will initiate an exit!)

Link to comment
Share on other sites

I won a T-Shirt for this set of macros in 2004!

 

Although the scripts were designed for Macro Express 3, updating them for Macro Express Pro should be straightforward.

 

"Escape to Close"

 

Thanks Alan, duly downloaded. I'm off on holiday tomorrow night so will install and try them on my return.

 

--

Terry, East Grinstead, UK

Link to comment
Share on other sites

  • 2 weeks later...

Here is an "improved" version of Esc to close scripts/Script Editor

 

Activation = Esc

Scope = "- Script Editor" (partial match)

 

What it does: Press Esc to close a script, one at a time.

 

Lock Player: Wait for running macros to stop

// Close the Script Editor, one script at a time.

// Rationale: Ctrl + F4 closes a script, but does nothing when only one script is open.

// When only one script is open, use Alt + F4 to close the Script Editor

 

// TopWindowTitle1 contains name of focused script...

Variable Set String %TopWindowTitle1% to topmost window title

// Try to close TopWindowTitle1 with Ctrl + F4

// (Does nothing if there is only one script open)

Text Type (Simulate Keystrokes): <CONTROL><F4>

Delay: 200 milliseconds

// TopWindowTitle2 contains name of focused window...

Variable Set String %TopWindowTitle2% to topmost window title

// If TopWindowTitle1 = TopWindowTitle2...

// The previous step did nothing. This means we can't use Ctrl + F4.

// So we close the Script Editor with Alt + F4

If Variable %TopWindowTitle1% Equals "%TopWindowTitle2%"

Text Type (Simulate Keystrokes): <ALT><F4>

End If

Unlock Player

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...