Save tabs separately as .rtf-files

Hi,

Problem: I have made a .rep consisting of 10 tabs. I want to refresh my query for client A, save each seperate tab as a rtf-file to a specified folder for client A. Refresh again for client B, save tabs as rtf, and so on for about 15 clients. Is there a VisualBasic-code to do this? Or any other way?

Thanks for helping.

Odem


Odem (BOB member since 2004-08-06)

This should get you started. It saves a .pdf.

Sub SavePDF()
 
    Dim boDoc As busobj.Document
    Dim Rpt As busobj.Report
        For Each Rpt In ThisDocument.Reports
        If Rpt.Name = "Tab Name Goes Here" Then
            Call Rpt.ExportAsPDF("C:\filename.pdf")
        End If
    Next Rpt
    
End Sub

You may find more examples if you do a search of the forum.

Welcome to BOB :mrgreen: .


Cindy Clayton :us: (BOB member since 2002-06-11)

Another example here, on the Integra Solutions site:

Filter and Export via VBA


Dave Rathbun :us: (BOB member since 2002-06-06)

Thanks!


Odem (BOB member since 2004-08-06)