$core_v2_email.Send issue not using fromEmailArg

#set($fromEmailArg="gggg@gg.com")

#set($toEmailArg ="sss@sss.com")

$core_v2_email.Send($subject, $body, "%{ FromEmail = $fromEmailArg, ToEmail = $toEmailArg}")

Even though we are specifying the fromEmailArg, the email is still being sent from the SMTP settings email ID. How can we force it to use the fromEmail specified in the script?