# Is there a way to make a formula for ci() functions that will return events for "today" or "tomorrow"?

Hi all,

I'm pretty new to kwgt, but I dig it. Big Tasker user, but kwgt takes things to a whole new level.

I'm trying to create a widget that lists meeting events for today or tomorrow only.

What I'm trying to do here is to check if the next 4 events start today or tomorrow, and make them visible if they do, or invisible if they start 2 days or more from today.

``````\$if(df(D) = df(D, ci(start, e0, a0d)) | df(D) = df(D, ci(start, e0, a1d)), always, remove)\$
\$if(df(D) = df(D, ci(start, e1, a0d)) | df(D) = df(D, ci(start, e1, a1d)), always, remove)\$
\$if(df(D) = df(D, ci(start, e2, a0d)) | df(D) = df(D, ci(start, e2, a1d)), always, remove)\$
\$if(df(D) = df(D, ci(start, e3, a0d)) | df(D) = df(D, ci(start, e3, a1d)), always, remove)\$
``````

It seems to work ok for events that are scheduled for today, but not for tomorrow.

Any suggestions?

Thanks a ton!

Joel Tomorrow is not \$df(D)\$ but \$df(D) +1\$, so your first formula should be:

`\$if(df(D) = df(D, ci(start, e0, a0d)) | (df(D) + 1) = df(D, ci(start, e0, a1d)), always, remove)\$`