Are you sure attribute index numbers is the best way to do this?
Copy and paste from one file to another, hotlink modules or simply a user creating a new attribute could all lead to the index numbers changing.
The general user really has no control over the attribute index numbers.
Building materials have an ID.
Any reason you can not add the code number to the ID?
Surfaces and fills are another mater - they don't have ID's - although I am sure there is a wish somewhere that they should.
There is also a wish to have a central attribute file that all other Archicad files can refer to.
It has certainly been discussed with the developers and is something they have said they would like to do.
Whether it happens or not I can't say.
But I hope it does.
One of the forum moderators.
Versions 6.5 to 25
Dell XPS- i7-6700 @ 3.4Ghz, 16GB ram, GeForce GTX 960 (2GB), Windows 10
Dell Precision 3510 - i7 6820HQ @ 2.70GHz, 16GB RAM, AMD FirePro W5130M, Windows 10