• delete remote table (Access 2000)

    Author
    Topic
    #366909

    I have a very nice function with which i used to delete a table in a remote database
    and then replace it.

    The function is the following

    Public Function FncRemoteProducts()
    Dim cat As New ADOX.Catalog, objConn As New ADODB.Connection
    objConn.Open “Provider= Microsoft.Jet.OLEDB.4.0;Data Source = C:bestorebe.mdb”
    With cat
    .ActiveConnection = objConn
    .Tables.Delete “products”
    End With
    DoCmd.TransferDatabase acExport, “Microsoft Access”, BEpath, acTable, “products”, “products”
    End Function

    Howver on some computers with WIndows 98 insteads of Windoes 2000 i receive the following

    Runtime error Active Component x cant create object
    I supose that the errors lies with ADOXDB, may be it is not existent in the older versions.
    Can somebody give me an advice how can i delete a remote table with the help of
    say DAO or something of the sort.
    I will be very grateful for the help

    Viewing 0 reply threads
    Author
    Replies
    • #570555

      Are you talking about running the code from a machine with Win98 or is the remote database on a Win98 machine? If you’re talking about running the code on Win98, have you installed MDAC on that machine?

      Win2k installs a version of MDAC with the OS but earlier Windows versions didn’t. Nor can you rely on any version installed by default to support the features you may use. There are at least 7 versions of ADO running around out there, and some of them are very bad indeed.

      • #570635

        Thank you very much for your prompt reply indeed. I am very impressed by this forum. Is there any function using DAO which drops table from a remote database?

        Best regards

        • #570808

          You would have to open an instance of the remote database in code and delete the table from the tabledefs collection. If you need help with that, post again. I’d suggest you start a new thread and specify DAO in the subject line. That will make it easier to find for anyone else looking for a similar answer.

    Viewing 0 reply threads
    Reply To: delete remote table (Access 2000)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: