The Omni Group
These forums are now read-only. Please visit our new forums to participate in discussion. A new account will be required to post in the new forums. For more info on the switch, see this post. Thank you!

Go Back   The Omni Group Forums > OmniFocus > OmniFocus Extras
FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
"activate" gone from Quick Entry too? Thread Tools Search this Thread Display Modes
Hi all,

Some time ago it seemed apparent that the "activate" AppleScript command stopped working for the OmniFocus app (or window, I can't recall). There is an easy workaround, so NBD.

However, "activate" still worked for the Quick Entry window (thanks BTW to Curt for showing me how). I use it all day long, for Capturing Firefox URLs and Capturing Lotus Notes URLs. I know that Curt's capture from Mac Mail script uses it too.

I noticed last night that it stopped working for me - I assume it broke in yesterday's update. I could still use my scripts to capture things without the QE window, but I'd prefer to have it working - the way the AppleScript support is changing I prefer to know for sure that the task was captured by seeing it with my eyes in QE.
  • Anyone know what's going on? Can you confirm that this is broken for you too?
  • Is there another way to bring the QE window to the front?
I'm an AppleScript noob - quite impressed with it so far, in fact I'm darn thankful for it, these capture capabilities are a must for me. It'll be nice though when the OF API settles.

Other QE window problems - related?
Also, earlier in the day yesterday, I noticed that the Quick Entry window started acting weird - if I invoked it with ^-alt-Space (not via Script), the QE window appeared but no first task was created - it just beeped as soon as the window was visible. The only way I could create a task was to click on the QE window to bring it forward, and then Cmd-} (create a child) created the task. Restarting OF fixed this, but it started doing it again before long. I don't know whether this is related to the Subject problem, but I do hope it gets fixed - I use QE via the hotkey all day long too.
 
There haven't been any recent scripting changes and this still works fine for me:

Code:
tell application "OmniFocus"
	activate quick entry
end tell
so maybe something else is going on.
__________________
CTO, The Omni Group
 
Thanks Tim for your reply.

That definitely isn't working here. Again, I'm new to AppleScript, so to determine how far my script is getting, I'm putting "display dialog" statements in. Given:

Code:
... beginning of script omitted
tell quick entry
    display dialog "about to execute activate"
    activate
    display dialog "still executing after the activate call"
    ... code to add new task
end tell
or, more like your snippet:

Code:
... beginning of script omitted 
display dialog "about to execute activate"
activate quick entry
display dialog "still executing after the activate call"
... code to add new task
... there are no error messages, but the "still executing" dialogs do not show and the work of adding the tasks does not get done. And this was working as recently as yesterday.

I'll keep digging, but I don't even know where to start looking for what might have happened

I was actually doing some scripting yesterday around the time this stopped working, trying to write a script that adds to the notes for a task and deleting some subtasks - you don't suppose I broke something permanently by messing around with AppleScript do you? I'd expect to be able to do some damage to my data, but not to the app...
 
Are you running your scripts in Script Editor or another scripting tool? At least one other tool has problems with our change to 'activate' taking a direct object parameter, so maybe that is related.

If the 'display dialog' calls aren't working, your script might be hitting an error before it gets there. If you have a 'try' block, it might be eating the error.

As far as breaking things -- running simple scripts shouldn't break the existing terminology. It could be that your scripting tool has cached the scripting dictionary incorrectly or otherwise gotten confused. If that's the case, restarting it should hopefully fix the problem.

As a side note, though it isn't published in the scripting suite (as it is a standard command), OmniFocus supports the "log" command, taking a string. This will go to /Applications/Utilities/Console.app and the Event Log in Script Editor (and presumably the equivalent in other tools). This can be a useful and less annoying alternative than 'display dialog'.

For example:

Code:
tell application "OmniFocus"
	log "hi!"
end tell
__________________
CTO, The Omni Group
 
Hi Tim,

I'll definitely start using "log" for my debugging - thanks for the tip.

Not using any special script editor - just the standard one that came on my Mac.

Restarting the script editor, but over the weekend I restarted the Mac - that seemed to fix it.

Thanks for your support Tim!
 
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
"Updating with sync data" : no quick entry option ? Tado OmniFocus for iPad 7 2012-05-11 02:54 PM
How to turn off "Quick Entry" when tapping "+"? santra OmniFocus for iPad 2 2011-05-31 09:25 AM
The "inbox" and "quick entry" buttons really annoy me! doodiebrad OmniFocus for iPad 53 2010-10-30 01:46 AM
Issue using AppleScript "activate" command chucksense OmniFocus Extras 2 2008-02-10 07:10 AM
Toggle from "Contexts" to the "Project the Entry belongs to"?? jkrytus OmniFocus 1 for Mac 1 2008-01-17 01:46 PM


All times are GMT -8. The time now is 02:56 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.