Results 1 to 4 of 4
  1. #1
    2 Star Lounger
    Join Date
    Nov 2001
    Posts
    192
    Thanks
    0
    Thanked 0 Times in 0 Posts

    delete remote table (Access 2000)

    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

  2. #2
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: delete remote table (Access 2000)

    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.
    Charlotte

  3. #3
    3 Star Lounger
    Join Date
    Jan 2001
    Posts
    254
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: delete remote table (Access 2000)

    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

  4. #4
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: delete remote table (Access 2000)

    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.
    Charlotte

Posting Permissions

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