4.x Report script

Does anyone know the command to export a report to a text file through Report script? I can convert to an excel file but the manual doesn’t say anything about exporting to a text file.

Any help would be appreciated.

Rob
Pearson Ed.


Listserv Archives (BOB member since 2002-06-25)

Rob - I’m afraid I don’t know the exact ReportScript command but wouldn’t it be along the lines of a Save As command ?

Darren.

Does anyone know the command to export a report to a text file through Report script? I can convert to an excel
file but the manual doesn’t say anything about exporting to a text file.

Any help would be appreciated.

Rob
Pearson Ed.


Listserv Archives (BOB member since 2002-06-25)

I asked the same question a week or so ago, and recieve the following reply from Dharma.


Listserv Archives (BOB member since 2002-06-25)

You want to call the function:
objectvar.ExportAsText(fileName)
where objectvar is your report object.
Simon


Listserv Archives (BOB member since 2002-06-25)

I am interested in exporting the raw data to a text file, not the actual report. Does anyone have a script that will export the raw data to a text file?

RV


Listserv Archives (BOB member since 2002-06-25)

d{095}exch/O=pearsontc/PRMD=pearson/ADMD=telemail/C=us/"@MHS> Mime-Version: 1.0

Ron

I believe the example provided earlier will convert a report to text. To export the data provider in 4.1.x as text try;

Sub main
dim dp as BODataProvider
set dp = ActiveDocument.DataProviders.Item(1) call dp.ConvertTo(ExpText,1,“Filename”)
End Sub

Mike McErlain
McErlain Consulting @ Cisco

At 04:26 PM 3/21/2000 -0500, you wrote:

I am interested in exporting the raw data to a text file, not the actual report. Does anyone have a script that will export the raw data to a text file? RV

Sub main
Dim app As BOApplication
Dim doc As BODocument
Dim reps As BOReports
Dim File_name As String
File_name = “C:\SPMetric4Data.txt”
On Error Resume Next
attribs=FileLen(File_name)
If attribs <> 0 then
kill (File_name)
end if
set doc = ActiveDocument
set app = Application
app.Interactive = FALSE
doc.Refresh
app.Interactive = TRUE
set reps = doc.Reports
reps.Item(1).ExportAsText(File_name)
doc.Close
End sub


Listserv Archives (BOB member since 2002-06-25)

In a message dated 00-03-21 16:24:43 EST, you write:

I am interested in exporting the raw data to a text file, not the actual report.
Does anyone have a script that will export the raw data to a text file?

It’s a bit confusing. The equivalent of the menu option “Save As” is written the the script language as ExportTo. The equivalent of the “Export” button on the data manager window is ConverTo. Example:

set dp = ActiveDocument.DataProviders.Item(1) call dp.ConvertTo(ExpAsciiTab,1,“OutPutFileName”)

Regards,
Dave Rathbun
Integra Solutions
www.islink.com


Listserv Archives (BOB member since 2002-06-25)