I've got a Sharepoint 2010 list that I'd like to filter with date-ranges. I'm doing something like
if END_DATE > [NOW - 1Week]
and END_DATE < [NOW + 1Week]
or PLAN_END > [NOW -1Week]
and PLAN_END < [NOW +1Week]
I will post the real code at the end of this post, but as it's just a bunch of code, it doesn't have too much of real relevance.
Now, when I use conditional formatting, I can use advanced expressions to make that happen (expression see below), but when using the list-view-webpart on a webpart-page - the additional formatting gets lost, which is intended behavior as I recall.
So I do not only have to hide the entries I dont want to see, I just do not have to select them in the first place (which makes more sense anyways). But is this possible via List-Filters? I know I can edit the code and write some XML-LINQ-Like expressions (forgive my terminology, really new to all this), but I can't find out how I would write the expression I need.
To sum it up: How can I FILTER a list with Date-Ranges?
And here the actual conditional formatting that I do (Hide all, where condition is not met)
not((ddwrt:DateTimeTick(ddwrt:GenDisplayName(string($thisNode/@Plan_x0020_Ende))) >= (ddwrt:DateTimeTick(ddwrt:Today())-(7*24*60*60*1000*10000)))
and (ddwrt:DateTimeTick(ddwrt:GenDisplayName(string($thisNode/@Plan_x0020_Ende))) <= (ddwrt:DateTimeTick(ddwrt:Today())+(7*24*60*60*1000*10000))))
and not((ddwrt:DateTimeTick(ddwrt:GenDisplayName(string($thisNode/@Ist_x0020_Ende))) >= (ddwrt:DateTimeTick(ddwrt:Today())-(7*24*60*60*1000*10000)))
and (ddwrt:DateTimeTick(ddwrt:GenDisplayName(string($thisNode/@Ist_x0020_Ende))) <= (ddwrt:DateTimeTick(ddwrt:Today())+(7*24*60*60*1000*10000))))