Do you need an actual validation message that prevents submitting?
If not, here's a quick option. I'm presuming this is an event that is called by the Year Built field since you used "this" as the parameter for your function.
if (this.rawValue > parseInt(dfPolicyTerm.rawValue.substr(0,4))){
xfa.host.messageBox(" ");
xfa.host.setFocus(this);
}