This example use the Refresh method on the Fields collection of a TableDef after rearranging the OrdinalPosition property of the fields.
See How to Build the DAO Method Samples.
If you have installed the DAO SDK, see InstallDirectory\DAOSDK\SAMPLES\Refresh.cpp.