Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Visual Basic > VB 6 Visual Basic 6 > Pro VB Databases
|
Pro VB Databases Advanced-level VB coding questions specific to using VB with databases. Beginning-level questions or issues not specific to database use will be redirected to other forums.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro VB Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old May 26th, 2004, 02:58 AM
Authorized User
 
Join Date: May 2004
Posts: 17
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to myedu2k4
Default Disconnect ADO Conn from Access DB

Hi there,
i write a program in VB6. I create public Ado Connection variable in a module.It connects to Db when the form is loaded. but when i disconnect it. Database is still open exclusively. I just wonder...
Anyone can help.? Please wellcome.

Pheap

 
Old May 26th, 2004, 09:03 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,189
Thanks: 5
Thanked 59 Times in 57 Posts
Send a message via MSN to gbianchi
Default

hi there..
can you put some code here??
do you unload the form and the conn is still open??

or you close your program and the conn is still alive???

HTH

Gonzalo
 
Old May 27th, 2004, 01:55 AM
Authorized User
 
Join Date: May 2004
Posts: 17
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to myedu2k4
Default

Hi,
It is simple when the form is loaded the connection alive. And i use the code to disconnect it (gAdoConn.Close;
  Set gAdoConn = Nothing)
If i close it in Form load even, the connection die,but if i load another form(last form still loaded) and i disconnect it(gAdoConn.Close) it still alive.
Anymore questions welcome...






Similar Threads
Thread Thread Starter Forum Replies Last Post
Cannot Disconnect DB amarjits Pro VB Databases 0 July 16th, 2007 12:27 AM
backup access db (ado) jolzy Pro VB Databases 1 November 2nd, 2004 04:41 AM
Populate combo box with access db with using ADO neo_jakey Pro VB Databases 1 October 23rd, 2004 10:11 AM
Populate combo box with access db with using ADO neo_jakey VB Databases Basics 3 October 13th, 2004 03:36 PM
Cannot connect DB though conn. tested sucessfully? Dragonist General .NET 5 August 5th, 2004 02:23 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.