CTREGWR is a general purpose method of setting internal function registers in the CTRIO. Pretty sure it works just fine.
CTAXCFG is the axis mode configuration function. It is the only way to get to axis mode. Is provides an option to set the axis position, which is simply setting the outputs internal output position register or the associated encoder's position register if configured for closed loop.
The bug is simply that the position register was being set prior to setting closed loop mode, hence, it thought it wasn't in closed loop mode and set the output register, rather than the encoder position. When you call it a second time it is already in closed loop mode and sets the encoder.
CTREGWR is actually aware of the output being in axis mode and sets the correct register when you write to the output position. If you were to write to the encoder position, it will set it regardless of the output mode...but the encoder input won't become the output position until the axis is in closed loop mode.
It all sounds pretty complicated, but it really isn't. There is one minor bug that prevents the CTAXCFG from correctly updating the encoder's position on the first call. That can be corrected by a second call to CTAXCFG, or by writing to the encoder's input position via CTREGWR...but...you must call CTAXCFG at least once to put the output in axis mode.