It is very clear what I want, yes I want to copy field code. In my previous post I was only saying that I thought your lisp worked when the field code was set in default value, not in the current value.
what i said (even twice) that the lisp will work only if the source attribute value contain field code
and i was wondering how come you are trying to test it on attributes that does not contain field code (see your notworking.dwg)
The field code was in the default value, and I assumed it was fine since you said you had tested it on example.dwg, which is exactly the same as NotWorking.dwg (no field code in the current value but in the default value only).
That's it. Just trying to understand how it works. If it works like that it would be great anyway. Changing the source value it's not a problem.
if you do not set the attributes value with field code then how can you expect the lisp will know want to copy?
See above. Obviously I am not an expert but I assumed it is possible to set the attribute value to the default value. I think it's possible but your lisp probably works in a different way (copying the current attribute value to the others) but I couldn't know that.
Now I am wondering why it asks if I want to change the source attribute value, if it has to be already changed to get it work.
it ask that cause there is always a change that you will select an not update attribute for example:
some how the block with X coords has moved but no regen or updatefield invoked.
I am happy with the explanation, but without knowing that you agree that, if I don't know how your lisp works and it asks if you want to update the source attribute, it's understandable to assume that there was no need to manually update the source attribute.
Also, see second part of my previous post. There are some other problems.
post the drawing with these problems (mark them somehow) so i can take a look
I am sure that your lisp works perfectly and this has something to do with my blocks definition, too many people working on the drawings over the months and the blocks are quite messed up. The funny thing is that on my drawings the lisp works on almost all the blocks but not all of them, but if I copy the blocks to another drawing it's never working, even for the blocks where it used to work. I tried to copy a couple of them and clean them up a little bit to reduce them to the essentials, and it doesn't work (see attached). But again, this has to do with my blocks so don't waste too much time on it, I am already totally happy with the proposed solution.