Thanks for this topic. I've been struggling with keeping YTD percentages up when using the google function.
I put this formula in and it works!... most of the time. Well, at least one mutual fund I have seems to return something drastically different that actual.
The fund is Fidelity® Contrafund® Fund Class K (FCNKX). When I just google the fund letters the YTD is 5.55%. When using the formula it returns .73%.
The formula I'm using is =IMPORTXML(concatenate("http://performance.morningstar.com/perform/Performance/fund/trailing-total-returns.action?&t=XNAS:",B7,"&Region=usa&culture=en-US&ops=clear&cur=&s=0P00001MJB&ndec=2&ep=true&ali g n=d&annlz=true&comparisonRemove=false&loccat=&taxa dj=&benchmarkSecId=&benchmarktype="), "//table/tbody[1]/tr[1]/td[5]")
Where b7 is FCNKX.
Am I missing something? I saw the latter post regarding exchanges, but when I used that formula I got nothing.
Thanks,
Bob D
.73% is as of 11/21/2018.
5.55% is as of 10/31/2018.
16.91% is as of 9/30/2018.
For the current day, simplify the formula to:
=IMPORTXML(concatenate("http://performance.morningstar.com/perform/Performance/fund/trailing-total-returns.action?&t=XNAS:",B7), "//table/tbody[1]/tr[1]/td[5]")
If you want the data as of the end of previous month, 10/31/2018, use this:
=IMPORTXML(concatenate("http://performance.morningstar.com/perform/Performance/fund/trailing-total-returns.action?align=m&t=XNAS:",B7), "//table/tbody[1]/tr[1]/td[5]")
For end of previous quarter, 9/30/2018, it's this:
=IMPORTXML(concatenate("http://performance.morningstar.com/perform/Performance/fund/trailing-total-returns.action?align=q&t=XNAS:",B7), "//table/tbody[1]/tr[1]/td[5]")