* C$ at C$0.9809 vs US$, or $1.0195 * Spain announces economic reforms and 2013 budget * China's central bank adds biggest weekly cash injection * BoC switching to long-term bonds to lock in rates By Solarina Ho TORONTO, Sept 27 (Reuters) - Canada's dollar finished stronger against the U.S. currency on Thursday, tracking gains in commodity prices and stock markets, helped by Spain's latest efforts to deal with its debt crisis and signs China might take more action to boost its economy. Spain, the euro zone's fourth-largest economy, announced a detailed timetable for economic reforms and a tough 2013 budget based mostly on spending cuts in what many see as an effort to pre-empt the likely conditions of an international bailout. The market "realized well, maybe, they don't have go to the EU (European Union) and it's not such a bad thing. I think that's really what turned the market around," said Steve Butler, managing director of foreign exchange trading at Scotiabank. "The biggest worry is that if they go to the EU and they really get their backs to the wall then they're stuck with an austerity program that may or may not work for them. So if they can do it themselves, then everybody feels like that's a better solution." Riskier assets were already cheered overnight by news that China's central bank had added its biggest weekly cash injection in history, aimed at preventing a potential short-term liquidity crunch at commercial banks. The move fueled talk that China may take steps to boost the country's weak stock market and sparked a global equities rally. "The headline overnight got the market on the right foot," said Butler. "With that we've seen stocks in positive territory all day, but Canada wasn't really appreciating ... we probably should've been doing better earlier in the day and we finally caught up." The Canadian dollar was trading at C$0.9809 to the U.S. dollar, or $1.0195, firmer than Wednesday's North American session close of C$0.9852, or $1.0150. It touched a session high of C$0.9792,or $1.0212 earlier. The currency was also supported by a jump in the price of gold and oil. Oil prices rose as tensions between Iran and the West stoked concerns about crude supplies, while refinery maintenance and low inventory levels drove U.S. gasoline futures to their highest since April. An array of U.S. data, meanwhile, painted a mixed economic picture, putting some pressure on the U.S. dollar. BOC SHIFT TO LONG BONDS The Bank of Canada announced that the government will reallocate short-term bond issuance towards long-term bonds as an extension of plans announced in the March budget to lock in funding at attractive rates. Canadian government bond prices were mostly lower. The two-year bond was off 2 Canadian cents to yield 1.100 percent, while the benchmark 10-year bond slipped 8 Canadian cents, yielding 1.753 percent.