Dates as measures: formatting (display as dates) + formulas

I need to use dates as measures in a dashboard

  1. If I use the “Siwtch as a measure” in the data cube, dates are simply counted not displayed as dates

    I would like that dates are formatted as dates but used as measures

  2. Then I would like to use formulas on thoses dates. By example calculating the difference between two dates

In fact, I need to draw a dashboard that would look like this:

Thanks a lot

Are the date formulas ones you can implement in the cube to create custom columns? Just add in a calculated column and write the code you need.