where is the input to your awk ? and what are you trying to achieve. If all you want is to assign value to variable you can do it directly right . whats the point in using awk ?
result = `awk '/<Main>/ { f=1 } f && /Amt/ { split($0,a,/[<>]/); s+=a[3] } /<\/Main>/ { f=0 } END {print s }' MyFile.xml`
echo "The result is " $result
But i am getting output as
result: 0653-690 Cannot open =.
result: 0653-690 Cannot open 23.
The result is