I suspect that many of you have already come across this in your day to day MDX'ing but just in case:
The standard YTD function only works with the Year level of Time hierarchies when the Attribute Type is set in the Basic Properties section to type Years.
If you have a Fiscal Hierarchy in your Time dimension and have the Type set to FiscalYears you will get #Value when you browse any measure using the YTD function.
If for any reason your application requires that Type FiscalYears is used then use PeriodsToDate instead of YTD as it is not affected by the Attribute Type.
Hope that helps.