Exported File is Empty or Database Error Appears


When I try to export a recordset to a PDF file, the file appears empty or throws an error.

The following error is displayed In the CSV and Excel format:

'File not found'

In the PDF format the following error appears:

"Runtimefout Microsoft VBScript error '800a01a8'. Object required: 'm_SourceRecordset'"

 Xml offers a file for download, but upon opening the file the following is displayed:

"The XML page cannot be displayed."

 What have I done wrong?

In Dreamweaver, switch to Code view and make sure that the UDE code bit is after the code that populates the Recordset and before the code that clears the results from the recordset:


<%@LANGUAGE="VBSCRIPT" codepage="65001"%>
<!--#include file="Connections/Server5.asp" -->
<!--#include file="ScriptLibrary/dmxDataExporter.asp" -->
<%
Dim Recordset1
Dim Recordset1_cmd
Dim Recordset1_numRows

Set Recordset1_cmd = Server.CreateObject ("ADODB.Command")
Recordset1_cmd.ActiveConnection = MM_Server5_STRING
Recordset1_cmd.CommandText = "SELECT * FROM dbo.Edition"
Recordset1_cmd.Prepared = true

Set Recordset1 = Recordset1_cmd.Execute
Recordset1_numRows = 0
%>
<%
' Universal Data Exporter ASP 1.0.0
' Type: pdf
dim  ude1
Set ude1 = New dmxPDFExporter
ude1.ScriptFolder = "ScriptLibrary"
ude1.Orientation = "P"
ude1.ShowPageNumbers = true
ude1.PageNumbersAlign = "L"
ude1.UseTitle = false
ude1.RowBgColor = "#FFFF66"
ude1.LineSize = 0.3
ude1.LineColor = "#000000"
ude1.StripHtmlTags = true
ude1.UseHeader = true
ude1.HeaderFont = "helvetica"
ude1.HeaderFontColor = "#FF0000"
ude1.HeaderFontSize = 12
ude1.HeaderBgColor = "#33FF99"
ude1.HeaderBold = false
ude1.HeaderItalic = false
ude1.FontName = "helvetica"
ude1.FontSize = 12
ude1.FontColor = "#000000"
ude1.CellBold = false
ude1.CellItalic = false
ude1.RowHeight = 10
ude1.FileName = "export"
ude1.SourceRecordset = Recordset1
ude1.SourceFieldsString = "MagazineID,MagazineID,50,C,L,Month,Month,50,C,L,Year,Year,50,C,L,Title,Title,50,C,L,Images,Images,50,C,L"
ude1.doExport

%>
<%
Recordset1.Close()
Set Recordset1 = Nothing
%>