Adjusting the analytical model in relation to another element

Hi,
I’m trying to Adjusting the analytical model of wall in relation to another wall.
I wrote the code below, but I get warning for the line:
“topAnalytical.ManuallyAdjust(refSource, refTarget)”
some one know what is the problem with the code??
thankscode2.pdf|attachment (239.2 KB)