Eastman Kodak Co has agreed to sell its online photo services business to Shutterfly Inc for $23.8 million, kicking off the bankrupt photography pioneer's relaunch as a much slimmer company although a patent sale seen crucial to its turnaround may still be months away.

The once-iconic company that invented the hand-held camera has said it will quit the camera business and is expected to fetch $1 billion to $2 billion from the sale of about 1,100 digital patents, which is due to get under way by June 30.

A source familiar with the patent sale said the process was moving forward, but added that the completion was not expected anytime soon.

Complicating the prospects is a dispute with computer giant Apple Inc over one of the patents.

At a hearing next week on March 8, a bankruptcy judge will hear Apple's motion to move forward with its patent-infringement suit. Apple has asked the bankruptcy court to lift the automatic stay applied to pending litigation against Kodak when the company filed for Chapter 11 on Jan. 19.

Kodak said the deal with Shutterfly followed a "stalking horse" bid -- a starting bid or minimally accepted offer that other bidders must surpass in a court-supervised auction -- from the web-based personal publishing service.

Shutterfly shares rose 18 percent to $31.70 in extended trade, following the news. The stock had closed at $26.91 on Thursday on the Nasdaq.

Shutterfly said it will transfer Kodak Gallery customer accounts and images in the United States and Canada to Shutterfly, and will allow customers to opt out of the transition if they do not want their photos to be transferred.

Kodak Gallery -- which enables users to store and share their own images and create custom printed photobooks, cards and albums -- has more than 75 million users.

PATENTS IN FOCUS

Kodak is focusing its consumer business on retail and destination photo solutions as well as home printing products, Pradeep Jotwani, president, consumer businesses and chief marketing officer of Kodak, said in a statement.

Shutterfly, which has millions of customers, bought privately held card design company Tiny Prints in a $333 million cash-and-stock deal last year.

It competes primarily with services such as Hewlett Packard's Snapfish, Kodak's EasyShare Gallery and American Greetings' Photoworks and Webshots brands.

The key focus for those watching Kodak's recovery effort, however, is progress in the patent sale.

"Kodak, the debtor, is under pressure from various creditors and constituents to liquidate its non-essential assets sooner rather than later," said bankruptcy lawyer Edward Neiger.

Apple has said the digital-imaging patents that Kodak must sell under terms of its $950 million bankruptcy loan may include a patent for which Apple said it is the rightful owner.

Apple declined comment, but has said in court papers that Kodak misappropriated Apple's technology to get the patent for a digital camera that can preview images on an LCD screen.

Kodak vehemently denies it infringed the patent.

"All of the patents at issue belong to Kodak, a fact that has been established in multiple prior court proceedings, including at the International Trade Commission. The validity of the patents ... has been upheld by the U.S. Patent Office, and in our licensing program that dates back ten years. There are more than 30 licensees to date," Kodak said in a statement.

Kodak's bankruptcy filing followed its failure to sell its patents outside of bankruptcy.

The case is In re: Eastman Kodak Co et al, U.S. Bankruptcy Court, Southern District of New York, No. 12-10202. (Additional reporting by Supantha Mukherjee in Bangalore; Editing by Anil D'Silva and Edmund Klamann)