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 1 for Mac
FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
So Task->Duplicate only works in project mode? Thread Tools Search this Thread Display Modes
Doggone-it… so many crappy things about stuff that's disabled in context mode. And so many ugly things about project mode and not being able to hide things :-(
 
You can duplicate a task in context mode, but it requires a work-around. If you option-drag a task to the same, or another, context in the Sidebar, the task will be duplicated. I've never understood myself why the Duplicate command doesn't work.
 
Quote:
Originally Posted by Greg Jones View Post
You can duplicate a task in context mode, but it requires a work-around. If you option-drag a task to the same, or another, context in the Sidebar, the task will be duplicated. I've never understood myself why the Duplicate command doesn't work.
Thanks for the tip!

I sorta figure duplicate doesn't work for the same reason sorting doesn't work :-/

I'm sure Rob Trew has a script which will do this (basically, a check-in which generates a follow-up task in 1-2 week's time) but I'm not loaded with scripts and it sure would be easy and fast for me to just do this manually.

There just so much UI friction in OmniFocus sometimes. And don't get me started on the split view in a task on the iPhone, or I might never get stopped. Functionality is great, scalability is great, UI and usability are poor :-(
 
This has come up before. It'll probably come up again.

If you duplicate (or create) a task in project mode, you can immediately see where it went and put it where you want it. Not so in context mode. Maybe you always want your duplicate task tucked in right behind the original, but I can't think of the last time where that was what I wanted to do with a duplicate. If you're in a restrictive view (next or available actions only in a sequential project, for example) the newly created action might not even appear (it doesn't in project mode). If you are going to modify the duplicate (changing the context, for example), it may get whisked off elsewhere in the display unless you are using a combination of view settings that makes context mode look similar to project mode. Given all of that, and the ease of right-click Focus in New Window where you can see what you are doing and don't have to disturb the current view, color me unconvinced that there's a far better way to do this. One might take the absence of the ability to paste into a context view in OmniFocus for iPad as an indication that they aren't actively moving to change this, either.

Sounds like you might want something like Curt Clifton's Complete and Await Reply script if you are doing this frequently.
 
Quote:
Originally Posted by whpalmer4 View Post
If you duplicate (or create) a task in project mode, you can immediately see where it went and put it where you want it. Not so in context mode. Maybe you always want your duplicate task tucked in right behind the original... If you're in a restrictive view (next or available actions only in a sequential project, for example) the newly created action might not even appear (it doesn't in project mode). If you are going to modify the duplicate (changing the context, for example), it may get whisked off elsewhere in the display unless you are using a combination of view settings that makes context mode look similar to project mode. Given all of that, and the ease of right-click Focus in New Window where you can see what you are doing and don't have to disturb the current view,
whpalmer4 you know OmniFocus much better than I do, so thanks for your explanations and helping explain why something shouldn't work. For me it is always helpful to understand the logic of why a requested feature might be bad for the way a program works.

I need help in understanding why an action would get whisked away if you duplicate it and you are still in the same view you were currently seeing the action. Wouldn't it have all the same values and still be visible?

Maybe there is a better way then duplicating an action for for what I need it for.

I am really just trying to duplicate an action that has a weekly or monthly repeating value and get back to it in a few days later. I don't want to just change the start day because when I complete the action, in the following week it will show up on the day I forwarded it to. I don't want to leave the original start date and keep seeing it the next few days as an available or next action and have to remind myself that I can't do that today.

So after duplicating the action I forward it and take off the repeat value, then mark the original repeating action as done (so it shows up on the same day next week) and then delete it (since it really wasn't done that day).

It would be nice to applescript all of those things in one step but the duplicating part has me the most hung up.

Is there no way for a script to check it's own context and project and then duplicate like "Delegated" or "Complete and Await Reply" does?

Last edited by skillet; 2011-09-14 at 10:15 AM..
 
Quote:
Originally Posted by skillet View Post
...I don't want to leave the original start date and keep seeing it the next few days as an available or next action and have to remind myself that I can't do that today.

So after duplicating the action I forward it and take off the repeat value, then mark the original repeating action as done (so it shows up on the same day next week) and then delete it (since it really wasn't done that day). ...
At the risk of sounding as if I am saying that you are doing this wrong (which is not what I mean) ... perhaps you are approaching your problem the wrong way. In a nutshell, it seems to me that you are playing games in OF to hide the fact that you do not want to do or cannot yet do a certain task on a certain list. Maybe instead, you should be deciding on one "action right now" list that you to reference when you really are doing actions. From that point, all other lists (perspectives, views ... whatever) exist only for reviewing projects/groups/actions/contexts ... where you purposely choose actions to move to your "action right now" list. Then, you should find a respectable way to keep your repeating actions off your "action right now" list until you really are ready to do it.

I think flagging is the most mentioned method for setting up an equivalent of an "action right now" list.

Just sharing what seems to be a tangential thought process that I had as I considered how to stop playing within OF to shift around my work loads and instead use OF to stay on top of what I am doing. Otherwise, I would imagine an AppleScript can be found or made to move tasks around as you want.

HTH

--
JJW
 
Thanks JJW for your comments, I posted all of that in hopes I can get help on a script or a better way to overcome this conveluted methode because you are right it is games with OF I am playing.

If I understand you correctly adding a standard tag like the day of the week to the comments or anything other than using the start date for the actions I view as actionable.

Currently I use flags for things I really should do for the day, like help someone out, practice goals I have etc., but that are not actually due that day. Repeating actions often don't fit into that category, so I couldn't flag them according to that method.

Anyway sorry if I have pulled this thread too far off topic. Duplicating an action with an AppleScript is still a dream of mine.
 
Quote:
Originally Posted by skillet View Post
I need help in understanding why an action would get whisked away if you duplicate it and you are still in the same view you were currently seeing the action. Wouldn't it have all the same values and still be visible?
I mentioned the whisking away would happen after you modified the duplicate (setting a new due or start date, for example, when grouping or sorting by same).
Quote:
I am really just trying to duplicate an action that has a weekly or monthly repeating value and get back to it in a few days later. I don't want to just change the start day because when I complete the action, in the following week it will show up on the day I forwarded it to. I don't want to leave the original start date and keep seeing it the next few days as an available or next action and have to remind myself that I can't do that today.
Okay, you've got a repeating task with a regular schedule, but this time around the schedule needs to be different. I just leave it as scheduled and mark it off when it gets done; my start and due perspectives (and forecast view on iPhone/iPad for due items) show me the things haven't been done on schedule, so they aren't immediately out of sight and out of mind. I have a look back at the start of the day and try to knock off any leftover items I can before turning to the new day's items, and when I exhaust the day's list or get near the end of the day, I'll look back again. Doing my project reviews also helps provide a safety net.

That said, I think it wouldn't be too hard to make a script that marked the item as complete (so the next one would be generated), then changed the original to be incomplete and non-repeating. But what do we do about the date? Does the script prompt for the new date, or just assign one, or leave that to the user? I'll give you three guesses as to which option is easiest to code :-)

If you were to create such a script, it might look something like this:

Code:
-- Reschedule Repeating Task

-- Solves issue of a repeating task that needs the current instance rescheduled without
-- disturbing the scheduling of future instances.  Current instance is marked complete to
-- generate the next instance, then set not to repeat and optionally rescheduled.

-- if pOffertoReschedule is true, prompt user for rescheduling, otherwise leave dates unmolested
property pOffertoReschedule : true

on run
	tell application "OmniFocus"
		tell front document
			tell document window 1
				set oTrees to selected trees of content
				set lngTrees to count of oTrees
				if (lngTrees > 0) then
					if (lngTrees = 1) then
						set oTask to value of (first item of oTrees)
						if (repetition of oTask is not missing value) then
							my RescheduleRepeatingTask(oTask)
						else
							display alert quote & name of oTask & quote & " is not a repeating task, ignoring"
						end if
					else
						display alert "Select only one row!"
					end if
				else
					display alert "No content selected!"
				end if
			end tell
		end tell
	end tell
end run

on RescheduleRepeatingTask(oTask)
	using terms from application "OmniFocus"
		
		set completed of oTask to true -- cause OmniFocus to duplicate task
		set repetition of oTask to missing value -- clear repeat
		set canReschedule to false
		if (pOffertoReschedule is true) then
			display dialog "Reschedule by how many days?" buttons {"Cancel", "OK"} ¬
				default button 2 default answer "1"
			set rescheduleDays to (text returned of the result) as integer
			
			-- attempt to move start and due dates back by rescheduleDays
			try
				tell oTask to set {theStartDate, theDueDate} to {start date, due date}
				set {newStartDate, newDueDate} to {theStartDate, theDueDate}
				
				if (theDueDate is not missing value) then
					set newDueDate to (theDueDate + (days * rescheduleDays))
					set canReschedule to true
				end if
				if (theStartDate is not missing value) then
					set newStartDate to (theStartDate + (days * rescheduleDays))
					set canReschedule to true
				end if
				if (canReschedule) then
					tell oTask to set {start date, due date} to {newStartDate, newDueDate}
				else
					display alert "No start or due date for existing task, duplicated but not rescheduled"
				end if
			on error
				display alert "Failed to reschedule existing task"
			end try
		end if
		
		set completed of oTask to false -- reactivate original task
		
	end using terms from
end RescheduleRepeatingTask
 
whpalmer4 (Bill) you are such a HUGE help, this answers many questions! I plan on spending a long time digesting this one and learning all I can from it.

Quote:
Originally Posted by whpalmer4 View Post

But what do we do about the date? Does the script prompt for the new date, or just assign one, or leave that to the user?
I was planning on using Dan's "Defer" script to ask for how long to defer it. I always like to defer from the current date; it's less thinking involved when trying to crank through a list.

Quote:
Originally Posted by whpalmer4 View Post

I'll give you three guesses as to which option is easiest to code :-)
I choose "C" leave that to the user. Thanks for showing me all three and for all the comments you made in your script, very helpful!

What is the "o" for in oTask? Is it for "on"? I gather "p" is a note that it's a property.
 
Quote:
Originally Posted by skillet View Post
I was planning on using Dan's "Defer" script to ask for how long to defer it. I always like to defer from the current date; it's less thinking involved when trying to crank through a list.
The logic in there now is very similar to the older version of Dan's script that I run, assuming you choose the option to adjust both start and due dates (which is what I do). Most of my deferring is just moving repeating actions to the same time next week, though now that someone finally wrote this script maybe I'll start using it :-)
Quote:
What is the "o" for in oTask? Is it for "on"?
Onomatopoeic :-)

Nah, I inherited it from Rob's code fragment, you'd have to ask him. Output? Original? I don't like to have names that are too similar to predefined names, and prefer not to rely on remembering rules (not a "language lawyer"!) about picky details. Is "Task" different than "task" in Applescript? In all cases? No such worries with "oTask"! I think I've probably read more of Rob's Applescript than anyone else's, so some of his style may have rubbed off on me, especially the part about writing scripts for others instead of focusing on one's own work at times :-)
 
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Duplicate a Project TomW OmniFocus for iPad 23 2012-04-29 09:20 AM
Cannot duplicate a task in context view? brab OmniFocus 1 for Mac 9 2011-03-05 04:05 AM
Duplicate Task Entries evansb OmniFocus 1 for Mac 2 2008-01-23 10:07 AM
Can't duplicate a task kastorff OmniFocus 1 for Mac 3 2007-12-20 07:22 PM
Can't duplicate actions in Context mode santra OmniFocus 1 for Mac 1 2007-12-19 07:00 PM


All times are GMT -8. The time now is 10:02 PM.


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