Ya resolvi el detalle de la conexion con el servidor SQL Server, este es el codigo que utilice para solucionarlo:
Código ASP:
Ver originalDim crReporte = New CrystalDecisions.CrystalReports.Engine.ReportDocument
Dim dsDataSet As New DataSet
Dim CRRepote_Datos = New Crystal_Reports1
Dim crExportOptions As ExportOptions
Dim crDiskFileDestinationsOptions As New DiskFileDestinationOptions
Dim crFormatTypeOptions As New PdfFormatOptions
Dim strFolder As String = "C:\Documentos PDF AZTECA\"
If Not Directory.Exists(strFolder) Then
Directory.CreateDirectory(strFolder)
End If
cadenaconexion = "Provider=SQLOLEDB;Data Source=GT\SQLEXPRESS2;Initial Catalog=es_fundacion;Persist Segurity Info=true;User ID=SA;Password=781acs"
Try
Abrir_Conexion()
datos_rep = "select a.al_folio,a.al_apepat,a.al_apemat,a.al_nombre,a.al_calle,a.al_numext,a.al_numint,a.al_cp,a.al_colonia,a.al_delmun,a.al_estado,"
datos_rep = datos_rep & "a.al_CURP,e.in_nombre1,e.in_cantidad1,e.in_nombre2,e.in_cantidad2,e.in_nombre3,e.in_cantidad3,e.in_nombre4,e.in_cantidad4,"
datos_rep = datos_rep & "e.in_nombre5,e.in_cantidad5,e.in_pagren,e.in_gasali,e.in_gastra,e.in_gasesp,e.in_gasrop,e.in_gasluz,e.in_gasagua,e.in_gastel,"
datos_rep = datos_rep & "e.in_gascel,e.in_gasint,e.in_gascab,"
datos_rep = datos_rep & "(e.in_pagren+e.in_gasali+e.in_gastra+e.in_gasesp+e.in_gasrop+e.in_gasluz+e.in_gasagua+e.in_gastel+e.in_gascel+e.in_gasint+"
datos_rep = datos_rep & "e.in_gascab)as totalgastos from [es_fundacion].dbo.alumno as a left join [es_fundacion].dbo.ingreso as e on "
datos_rep = datos_rep & "a.al_folio=e.al_folio where a.al_folio=" & nfolio
Dim daDataAdapter As New OleDbDataAdapter(datos_rep, cadenaconexion)
daDataAdapter.Fill(dsDataSet, "DPT")
CRRepote_Datos.SetDataSource(dsDataSet.Tables("DPT"))
crDiskFileDestinationsOptions.DiskFileName = strFolder & nfolio & ".pdf"
crExportOptions = CRRepote_Datos.ExportOptions
With crExportOptions
.ExportDestinationType = ExportDestinationType.DiskFile
.ExportFormatType = ExportFormatType.PortableDocFormat
.DestinationOptions = crDiskFileDestinationsOptions
.FormatOptions = crFormatTypeOptions
End With
CRRepote_Datos.Export()
CRRepote_Datos.Close()
labmensaje.Visible = True
Catch ex As Exception
Response.Write("Error al momento de generar el archivo </ br>")
Response.Write(ex)
Response.End()
End Try