borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2010 Andrea Tincaniborder

AndreaVB | Forum | News | Downloads | Register | Help | Member List | Statistics | Search | PM | Profile

Print This Topic
Previous Topic (Can You believe?)Next Topic (how to generate multiple report!!!!!) New Topic New Poll Post Reply
AndreaVB Forum : Reporting tools : vb6 How to connect crystal report 10 with SQL SERVER 2000 or 2005
Poster Message
VYX
Level: Professor


Registered: 16-12-2005
Posts: 77

Ads by Lake Quincy Media
icon vb6 How to connect crystal report 10 with SQL SERVER 2000 or 2005

How to connect crystal report 10 with SQL SERVER 2000 or 2005
--------------------------------------------------------------------------------

Hello guys..

Im working with an application on how to create a vb6 report program with sql server 2000/2005 or mysql 5.0 with external report crystal report 10.

I saw several post regarding connecting crystal report 8.5 with access database. but im using crystal report 10 developer edition and vb6.

How to code this please help.. Is there any sample code on how to view a report. that a record from sql server 2000-2005

thanks

I'm looking forward for  you all.

Thanks in advance.

09-09-2009 at 06:57 AM
View Profile Send Email to User Show All Posts | Quote Reply
VYX
Level: Professor


Registered: 16-12-2005
Posts: 77
icon Re:need Urgent Help. vb6 How to connect crystal report 10 with SQL SERVER 2000 or 2005

Guys..

Please take a look to these code

    
    Dim CrxApp As CRAXDRT.Application
    Dim CrxRep As CRAXDRT.Report
    Dim crxDatabase As CRAXDRT.Database
    Dim crxDatabaseTables As CRAXDRT.DatabaseTables
    Dim crxDatabaseTable As CRAXDRT.DatabaseTable

    Set CrxApp = New CRAXDRT.Application
    Set CrxRep = CrxApp.OpenReport(vRptLocation & "\" & vrptFilename & ".rpt")
    
    Set crxDatabase = CrxRep.Database
    Set crxDatabaseTables = crxDatabase.Tables
      

        For Each crxDatabaseTable In crxDatabaseTables
                       crxDatabaseTable.SetLogOnInfo "(local)", "dbTest", "vID", "vPw"
       Next crxDatabaseTable


        With CrxRep        
        .SQLQueryString = "select * from tbltable"  '''>>>>i got the error here (i got this error number... -2147189176(80047e48))

        End With
    

    End If


        With crView
            .ReportSource = CrxRep
            .ViewReport
                        
            While .IsBusy
                DoEvents
            Wend
            .visible = False
            .Refresh
        End With

''''''''''''''''''''''''''''''''''''''''''''''''
i got this error number... -2147189176(80047e48)
logon failed.
details: dao error code : 0xbd4
source: dao.dbengine
descripton:cannot start your application. the workgroup information file is missing or opened exclusively by another user
'''''''''''''''''''''''''''''''''''''''''''''''
i try to close the crystal report,sql server and shutdown also but still didn't work...

Please help guys..

thanks in advance..

vyx

11-09-2009 at 02:48 AM
View Profile Send Email to User Show All Posts | Quote Reply
AndreaVB Forum : Reporting tools : vb6 How to connect crystal report 10 with SQL SERVER 2000 or 2005
Previous Topic (Can You believe?)Next Topic (how to generate multiple report!!!!!) New Topic New Poll Post Reply
Surf To:


Not Logged In? Username: Password: Lost your password?
Partners: Download Actual Software | Free Software Download
borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2010 Andrea Tincaniborder