You can call the ResetTarget() function in your code by changing the below line
ScriptManager.RegisterStartupScript(this.GetType(), "displayScript","<script language='javascript'>return ResetTarget();</script>");
if you dont't want to call further any other function then pass return false after you function
function ResetTarget() {
alert('Yes');
document.forms[0].target = '';
return false;
}