What Is ADOX?

 < Day Day Up > 

In the last several chapters, you've learned how to use ADO to explore and manipulate data. But there are limitations to the things that you can do with ADO. One of these limitations is that ADO can work only with objects that already exist in the database. You can't, for example, create a new table or a new query with ADO, no matter what you do with the Connection, Command, or Recordset objects.

Many developers might never feel this limitation, but being able to create new objects from code can be incredibly useful. For example, you might have some tables that you prefer to start with in every database that you create. Wouldn't it be nice to run a procedure to just create these tables, instead of working in the table designer?

That's why Microsoft invented ADOX more formally, the ADO Extensions for DDL and Security. This is an additional library that hooks in with ADO to enable creating new objects. This chapter exposes you to some of the features and functions of ADOX.

As the name implies, ADOX also enables you to manipulate the security properties of objects in your database, such as who owns an object and who has permission to work with the object.

Figure 18.1 shows the part of the ADOX object model used in this chapter.

Figure 18.1. Part of the ADOX object model.



The Connection object shown in Figure 18.1 is not really part of ADOX. Rather, it's the standard ADO Connection object. The two libraries interface by sharing this object.

     < Day Day Up > 

    Automating Microsoft Access with VBA
    Automating Microsoft Access with VBA
    ISBN: 0789732440
    EAN: 2147483647
    Year: 2003
    Pages: 186

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net