C1 Community
ComponentOne Community is a free source for developers and help authors to collaborate and communicate.

Export to RTF From VSPrint

rated by 0 users
This post has 1 Reply | 1 Follower

Not Ranked
Posts 4
g7su5ue5 Posted: Tue, Dec 9 2008 11:49 PM

Hi everyone!

I am using VSPrint in a Web Application and I want to export preview page to *.rtf file. How can I do it?

Top 25 Contributor
Posts 456
Hello,
 
You may use the TextRTF Property or ExportFile Property to get the desired functionality:
 
The code below shows how you can use the same code to generate regular output, HTML, or RTF files:

Private Sub CreateDocument(sFile As String)

  With vp

    ' set up to export RTF, HTML, or nothing

    .ExportFile = ""

    If Instr(sFile, ".rtf") Then

      .ExportFile = sFile

      .ExportFormat = vpxRTF

    ElseIf Instr(sFile, ".htm") Then

      .ExportFile = sFile

      .ExportFormat = vpxDHTML

    End If

    ' create document

    .StartDoc

    CreateDocumentBody

    .EndDoc

    ' clear ExportFile to avoid overwriting it

    .ExportFile = ""

End Sub

Have a nice day.

Regards,

James Smith

 
 
<g7su5ue5> wrote in message news:212260@10.0.1.98...

Hi everyone!

I am using VSPrint in a Web Application and I want to export preview page to *.rtf file. How can I do it?



http://helpcentral.componentone.com/cs/forums/p/77551/212260.aspx#212260

Page 1 of 1 (2 items) | RSS
Contact ComponentOne: 1.800.858.2739 ©1987-2010 ComponentOne LLC All Rights Reserved.