T
TC
(untested)
dim db as database, td as tabledef, inx as index, fld as field
set db = currentdb()
set td = db.tabledefs![YourTableNameHere]
for each inx in td.indexes
if inx.primary then
for each fld in inx.fields
msgbox fld.name
next
endif
next
set td = nothing
set db = nothing
HTH,
TC
dim db as database, td as tabledef, inx as index, fld as field
set db = currentdb()
set td = db.tabledefs![YourTableNameHere]
for each inx in td.indexes
if inx.primary then
for each fld in inx.fields
msgbox fld.name
next
endif
next
set td = nothing
set db = nothing
HTH,
TC