开发者

printing a doc file using cocoa

I'm looking fo开发者_Python百科r a simple code to print the contents of a MS Word file (.doc, .docx) using Cocoa. I'm a newbie to Cocoa. Someone please help.


Mac OS? Doc format is supported by NSAttributedString, which means it can be opened in an NSTextView. You print a doc file the same as you print most other text/rich text files. You can do it with an off-screen text view if you don't want to force the user to view it before printing.

There is some good example code for printing from an off-screen NSTextView on the CocoaDev wiki.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜