In you worklfow, you could use the "Add Time To Date" : Add Time to Date (nintex.com)
And passe a nagative number to get X date befor your end date
After make a "Pause until date"
And then send your Email or task.
But be warn that with this solution you will have some worklfow that will wait until the end date .... so if you have a large number of item this can this can cause problems (you can have a maximum of 100 instances of a workflow in the same time on a list)
I recommande you to make a site workflow that is scheduled every day. In The workflow you calculated a date (Today + 4days) retrieve all the elements that match your "ElementEndDate = CalculatedDate" and make a foreach on all the items retrived, then send a email or start a workflow on this items (this workflow will create a task)
Hi Nico,
When I try to do negative date values the workflow instance suspends and I get the following message.
RequestorId: e8ba78ea-7792-d681-0000-000000000000. Details: An unhandled exception occurred during the execution of the workflow instance. Exception details: System.ArgumentOutOfRangeException: The added or subtracted value results in an un-representable DateTime. Parameter name: value at System.DateTime.AddTicks(Int64 value) at Microsoft.Activities.Expressions.AddToDate.Execute(CodeActivityContext context) at System.Activities.CodeActivity`1.InternalExecute(ActivityInstance instance, ActivityExecutor executor, BookmarkManager bookmarkManager) at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation) Exception from activity