As far as I know, this is not possible. You could try to duplicate your date fields, and set their format to correlate. Then use your parameter to call upon whichever field you want to use.
There are ways that you can 'fool' the user in showing the correct granularity.
This can be done by using a parameter that switches between visualizations. The only downside is that you need to create a seperate visualizaton for every granularity that you like to show.
In case you don't like to do this, then Wim is right. There is not really another option.
I attached an example.
Hello Wim, Matthias,
Thanks for your answers ! Matthias, your trick may help in some cases so I'll definitely give it a try