There's not really enough sample code to see what might be causing the problem -- maybe you could post a more detailed example?
At a guess, however, your ResultTarget is targetting the wrong thing. If you replace the InvokeCommand with a simple static SET to the same target, does it then work as expected?
Eddy