Results 1 to 9 of 9

Thread: ** RESOLVED ** [2005] BO XI R2 db connection issue

Threaded View

  1. #1

    Thread Starter
    PowerPoster Pasvorto's Avatar
    Join Date
    Oct 2002
    Location
    Minnesota, USA
    Posts
    2,951

    ** RESOLVED ** [2005] BO XI R2 db connection issue

    I am having a problem trying to figure out how to have a report connect to two databases. I have one db that contains tooling data, but I also need to connect to another db that has product description data. I thought I might be able to do this:
    VB Code:
    1. Case "Z:\Tooling\Xref.rpt"
    2.                 ReportPath = Application.StartupPath & "\Xref.rpt"
    3.                 CRViewer1.ReportSource = ReportPath
    4.                 Dim myTableLogOnInfos As TableLogOnInfos = CRViewer1.LogOnInfo
    5.  
    6.                 For Each myTableLogOnInfo As TableLogOnInfo In myTableLogOnInfos
    7.                     If report.name = "Unprinted" Then
    8.                         myTableLogOnInfo.ConnectionInfo = myConnecionInfo2
    9.                     Else
    10.                         myTableLogOnInfo.ConnectionInfo = myConnecionInfo
    11.                     End If
    12.                 Next

    That does nto seem to be working. I can't seem to find out how to determine the table name that it is trying to cvonnect to. Also, it is telling me that myConnectionInfo & myConnectionInfo2 are not defined. Yet at the top of the subroutine I have:

    VB Code:
    1. Dim myConnectionInfo As ConnectionInfo
    2.         Dim myConnectionInfo2 As ConnectionInfo
    3.         Dim ReportPath As String
    4.         Dim mySelectionFormula As String = ""
    5.         myConnectionInfo = New ConnectionInfo
    6.         With myConnectionInfo
    7.             .ServerName = "Primero"
    8.             .DatabaseName = "Tooling"
    9.             .UserID = "sa"
    10.             .Password = myPasswordTechniSQL
    11.         End With
    12.         With myConnectionInfo2
    13.             .ServerName = "Primero"
    14.             .DatabaseName = "Techni"
    15.             .UserID = "sa"
    16.             .Password = myPasswordTechniSQL
    17.         End With
    Last edited by Pasvorto; Nov 21st, 2006 at 10:55 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width