• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 8. Opening Databases > Opening the Connection

Opening the Connection

With the connection declared, you can open it wherever it makes sense to do so in your VBA code. After it's open, you can begin to move data back and forth across the connection.

This is another area that highlights the flexibility in ADO: As you'll see, it's even possible to establish the connection and open it simultaneously. Depending on your preferences, you can provide the connection string to the Connection object directly, as shown in the prior section. Or you can provide it as an argument to the Connection object's Open method, as shown in the following sections.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint