CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Jun 2003
    Location
    India
    Posts
    22

    Database Connection

    Hi,
    Very Urgent.

    I use Data Environment
    I Create SQL Server 7.0 Database at run-time using SQL-DMO
    After creating Database I connect it using following code.

    'CmpStr is Connection String

    DB.Cmp.Open CmpStr

    Case #1
    It is running Ok on my PC. It Create DB connects it and working smothly.

    Case #2

    From my client PC it is not running, IT Creates database but after creating database it can't connect to database

    Error No : 713
    Desc : Application Error or Object Defined Error

    My PC and Client PC configuration is also same, both have SQL Server MSDE Installed (Same), Windows 98 SE.

    Please help me in this. How I can Solve this problem.
    Satish

  2. #2
    Join Date
    Nov 2002
    Posts
    278
    The Data Report run-time file (Msdbrptr.dll) must be on the PC that’s giving you the error.

    See MS URL below. . .


    http://support.microsoft.com/default...NoWebContent=1

  3. #3
    Join Date
    Aug 2002
    Location
    malaysia
    Posts
    234
    DinoVaught,
    after read through the thread, i would like to ask something regarding to the client and server's problem.

    i have a database in my server. how do i do the connection from my client PC?

    this is the connection that i have done for my server PC
    Public boss_cn As ADODB.Connection
    Public my_cn As ADODB.Connection
    Public Function DBConnect() As Boolean

    On Error GoTo OpenErr

    Dim BOSSDatabase
    Dim MYDatabase

    Set my_cn = New ADODB.Connection

    MYDatabase = App.Path & "\" & "my" & Format$(Now(), "ddmmyyyy") & ".mdb"
    my_cn.CursorLocation = adUseClient
    my_cn.Provider = "Microsoft.Jet.OLEDB.4.0"
    my_cn.Open MYDatabase, Admin

    Set boss_cn = New ADODB.Connection

    BOSSDatabase = App.Path & "\" & "bs" & Format$(Now(), "ddmmyyyy") & ".mdb"
    boss_cn.CursorLocation = adUseClient
    boss_cn.Provider = "Microsoft.Jet.OLEDB.4.0"
    boss_cn.Open BOSSDatabase, Admin



    DBConnect = True



    Exit Function


    OpenErr:

    MsgBox "Error Opening " & MSDatabase & vbNewLine & Err.Description, vbCritical, "Open Database Error"
    DBConnect = False


    End Function

    this is my server connection to the database and it work fine.
    the question is how do i code the path if i connect it from a client PC? so that, the client PC can also get access to the database in the server's PC.

    thanks,
    gechin

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

Featured