Skip to Content
0
Former Member
Feb 16, 2009 at 09:23 AM

Database vendor error 556?

705 Views

Hi,

I use CR XI (sp4) at runtime to print report using an ODBC connection to text files, my project is working fine except on one computer where i have an error message (database vendor error 556) . I used the same method to install this PC (runtime install and project install) and i don't understand why i have this error on this PC.

Here is my code:

Private Sub Connection( Fichier, IndTable)
    Dim i As Integer
    Dim FicN As String
    FicN = Mid(Fichier, 1, Len(Fichier) - 4) & "_txt" ' Replace(Fichier, ".txt", "_txt", , , vbTextCompare)
    If IndTable = 1 Then rptReport.Database.Tables(IndTable).SetDataSource cnn1
    rptReport.Database.Tables(IndTable).name = FicN
    rptReport.Database.Tables(IndTable).Location = Fichier
    DoEvents
End Sub

In my example

Fichier = xxxx.txt , FicN = xxxx_txt

Error occurs at line : rptReport.Database.Tables(IndTable).Location = Fichier

My dsn file is located on : c:\Program Files\Fichiers communs\ODBC\Data Sources.

Thanks in advance for help.

Vincent