* FTSEurofirst 300 ends up 0.5 pct; hits 5-wk closing high
* Financials surge on UBS results, Basel scale-back
* BP falls 2.6 pct; posts huge losses, changes CEO
By Atul Prakash
LONDON, July 27 (Reuters) - European shares rose to a five-week closing high on Tuesday as strong results from UBS <UBSN.VX> boosted banks, but more than half the market's early gains were erased after data showed a drop in U.S. consumer confidence.
The FTSEurofirst 300 <
> index of top European shares advanced for a sixth straight session to finish 0.5 percent firmer at 1,054.17 points, its highest close since June 21, but much lower than the index's intra-day high of 1,061.46.Banks raced higher, with the STOXX Europe 600 banking index <.SX7P> rising 4.7 percent, after UBS posted second-quarter net profit well above forecasts. The sector was also boosted by a scale-back of looming capital reforms and a longer timeframe to implement changes. [
]UBS surged 11 percent, while Societe Generale <SOGN.PA>, Barclays <BARC.L> and Credit Agricole <CAGR.PA> rose between 7.7 and 10.6 percent.
"People are still cautious and only adjusting their positions in line with the climbing market. We have enough buying power standing on the sidelines and have potential to test the upper trading range," said Giuseppe-Guido Amato, strategist at Lang & Schwarz in Frankfurt.
"We have a fight between company results and economic data -- company numbers on the good side and economic numbers on the evil side. It's important we trigger the upper resistance. If we don't, then I am very sceptical about the autumn because (economic) data will remain weak and the earnings season will fade out."
European shares erased a significant part of earlier gains after data showing U.S. consumer confidence sank in July to its lowest since February, underscoring the slow path to economic recovery. U.S. home prices rose in May but without signs of a sustained rebound. [
]Among oil stocks, BP <BP.L> slipped 2.6 percent. It unveiled a $17 billion quarterly loss due to the costs of the Gulf of Mexico oil spill, but launched a plan to repair its battered image, ditching its chief executive and promising to slim down by trebling an asset sale target to $30 billion. [
]"For now ... despite some other concerns that we may have particularly over performance of the chairman this past three months, we may hope that our overriding concern on BP right now will soon enough disappear," said Howard Wheeldon, senior strategist at BGC Partners.
TECHNICAL PICTURE
The Euro STOXX 50 <
>, the euro zone's blue chip index, was up 1 percent at 2,769.31 points. It faces the next near-term resistance at around 2,805 points -- its 200-day moving average and a 61.8 percent Fibonacci retracement of a fall from a high in April to a low in May."The index is displaying a good upside momentum on a short-term view. It's moving through apparent resistance levels, which is a bullish phenomenon," said Bill McNamara, technical analyst at Charles Stanley.
"Although there are further potential resistance points on the immediate horizon, there is not very much in the chart to say that the rally is about to run out of steam."
Daimler <DAIGn.DE> was among the top blue-chip decliners, down 4.2 percent following full results for the second quarter. Analysts attributed the drop to profit-taking after it said two weeks ago with preliminary figures that it would raise its 2010 guidance for a second time. [
]French food group Danone <DANO.PA> fell 4.2 percent. It said its operating margin would stay flat this year as the economic crisis hurts consumer demand in Europe.
Across Europe, the FTSE 100 <
>, Germany's DAX < > and France's CAC 40 < > rose 0.2 to 0.8 percent, while the Thomson Reuters Peripheral Eurozone Countries Index <.TRXFLDPIPU> was up 1.8 percent. (Editing by David Holmes)