Marcus, Scott (GEAE, RHI Consulting)
scott.marcus at ae.ge.com
Wed Mar 12 12:49:00 CST 2003
Straight form the Access97 Help file... Sub DropX1() Dim dbs As Database ' Modify this line to include the path to Northwind ' on your computer. Set dbs = OpenDatabase("Northwind.mdb") ' Delete NewIndex from the Employees table. dbs.Execute "DROP INDEX NewIndex ON Employees;" dbs.Close End Sub Scott -----Original Message----- From: John Skolits [mailto:JSkolits at corporatedatadesign.com] Sent: Wednesday, March 12, 2003 1:44 PM To: AccessD at databaseadvisors.com Subject: [AccessD] How to Delete or modify an index in VBA Anyone know how to delete an index in VBA after it's already been added to a collection. Another option would be to modify it (add a field) or to set it's Unique property to false. Any of these would be fine. I know how to Create an index, just can't delete it. I am using DAO but could also use ADO if that's the better solution. John Skolits _______________________________________________ AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com