当前位置: 动力学知识库 > 问答 > 编程问答 >

How to print an image in iOS 4.2?

问题描述:

I find the Apple documentation difficult to read through. Perhaps someone out there is willing to share some code on how to easily print a JPG or PNG file in iOS 4.2?

网友答案:

There are three basic steps:

  1. Instantiate an NSData object from your file.
  2. Create a UIPrintInfo object that contains the job specs.
  3. Send the data to a UIPrintInteractionController, which will begin the process.

See this article for a code sample.

分享给朋友:
您可能感兴趣的文章:
随机阅读: