(Reuters) - Apple Inc on Tuesday delivered surprisingly strong fiscal third-quarter earnings and signaled that its upcoming 10th-anniversary phone lineup is on schedule, driving the stock up 6 percent to an all-time high in after-hours trading.

The stock climbed above its intraday record high to $159.10 after the company reported better-than-expected iPhone sales, revenue and earnings per share. The stock price move was expected to help drive the Dow Jones Industrial Average over the 22,000 mark on Wednesday.

Apple also said it hit a milestone of 1.2 billion iPhones sold.

The April-June quarter is traditionally a soft one for Apple as the market waits for the September launch of new iPhone models. But Tuesday’s results show that iPhone buyers may be less inclined than they once were to delay purchases until a new model is out.

The iPad product lines also showed unexpected strength, service revenue continues to grow at a healthy clip, and even the much-maligned Apple Watch showed a 50 percent sales increase.

Apple is widely tipped to adopt higher-resolution OLED displays for the latest iPhone, along with better touchscreen technology and wireless charging - which could come with a $1,000 plus price tag.

The phone is expected to launch in September.

The company forecast total revenue of between $49 billion and $52 billion for the current fourth quarter, while analysts on average were expecting $49.21 billion, according to Thomson Reuters I/B/E/S.

Apple’s fourth quarter generally includes first-weekend sales of the company’s latest devices.

The forecast “makes it fairly certain that at least some new iPhone models will be released on the normal schedule,” said analyst Jan Dawson of Jackdaw Research. “That doesn’t necessarily mean all new models will go on sale then, or that they’ll all be in abundant supply, but I would think it means that at the very least the successors to the current phones will be available.”

But Bob O’Donnell, chief analyst at TECHnalysis Research, cautioned that if Apple releases cheaper models before the premium models in its 10th anniversary phone lineup, the cheaper models could dampen sales of more expensive units released closer to the holidays.

The company said iPhone sales rose 1.6 percent to 41.03 million in the third quarter ended July 1, above analysts’ average estimate of 40.7 million units, according to FactSet StreetAccount. Apple sold 40.4 million iPhones a year earlier.

But a lower average iPhone selling price of $606, well below Wall Street expectations of $621, caused iPhone revenue to come in at $24.8 billion, below expectations of $25.5 billion.

A woman looks at the screen of her mobile phone in front of an Apple logo outside its store in Shanghai, China July 30, 2017. REUTERS/Aly Song

Apple Chief Financial Officer Luca Maestri told Reuters the weak price was partly explained by Apple lowering the flow of inventory by 3.3 million units, which he said were “entirely at the high end of the range.”

Apple reports how many phones it sells to retailers, not how many phones it sells to consumers, what is known as a sell-in basis. When factoring how many existing “high end” phones the company cleared out of retail inventory, Maestri said average selling prices were higher.

The company’s net income rose to $8.72 billion, or $1.67 per share, from $7.80 billion, or $1.42 per share, a year earlier.

Revenue rose to $45.41 billion from $42.36 billion in the quarter, typically the company’s weakest, beating expectations of $44.89 billion.

CHINA REVENUE DOWN, AUTONOMY TO THE FUTURE

Apple said revenue from emerging markets excluding China grew 18 percent, a bright spot. But sales from the Greater China region fell 9.5 percent to $8 billion in the latest quarter, as consumers switched to newer domestic offerings.

The decline was smaller than recent quarters. Apple’s Maestri said mainland China revenue was flat, as were iPhone sales in the mainland. Sales of other Apple products rose in mainland China and were also up in Taiwan.

“The decline from a market standpoint was concentrated in Hong Kong, which is a place that has been really affected by a reduction in tourism because the Hong Kong Dollar is pegged to the U.S. dollar,” Maestri said.

Apple CEO Tim Cook also directly addressed the company’s decision to remove so-called VPN apps from the App Store in China. Those apps help Chinese users circumnavigate government internet restrictions.

“We would obviously rather not remove the apps, but like we do in other countries we follow the law wherever we do business,” Cook said. “We believe in engaging with governments even when we disagree. This particular case, we’re hopeful that over time the restrictions we’re seeing are lessened, because innovation really requires freedom to collaborate and communicate.”

Strong iPad sales of $4.9 billion - almost $1 billion above Wall Street expectations - and a 21.6 percent jump in the company’s services business that includes the App Store also helped boost revenue. In particular, Apple said that Walmart Stores Inc would buy 19,000 iPads to train as many as 225,000 employees. The company also said it increased production of AirPods, its wireless headphones.

Apple CEO Tim Cook declined to directly address U.S. President Donald Trump’s claims that Apple will build three new factories in the U.S., instead citing the company’s job creation efforts and a $1 billion U.S. manufacturing fund.

Cook also hinted that Apple’s experiments with self-driving cars may include ambitions that extend beyond cars. He said the company is making a “big investment” in autonomous systems.

“From our point of view, autonomy is sort of the mother of all AI projects,” Cook said. “And the autonomous systems can be used in a variety of ways, and a vehicle is only one, but there are many different areas of it. And I don’t want to go any further with that.”