# Error Processing

**URL:** <https://forum.kirupa.com/t/error-processing/41861>\
**Category:** flash\
**Created:** [February 2, 2004, 8:03pm UTC](https://forum.kirupa.com/t/error-processing/41861 "2004-02-02T20:03:31Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![mistercheezit](https://avatars.discourse-cdn.com/v4/letter/m/a3d4f5/32.png) [@mistercheezit](https://forum.kirupa.com/u/mistercheezit)\
**Post date:** [February 2, 2004, 8:03pm UTC](https://forum.kirupa.com/t/error-processing/41861/1 "2004-02-02T20:03:31Z")

</div>

Can someone tell me what is wrong with my AS here? I’m trying to make a simple form which error checks and then outputs to ASP but it won’t do anything when I click ‘submit’.

```auto

var email_lv = new LoadVars();
function validate() {
	var p = this._parent;
	var _lv = p.email_lv;
	if (p.name_txt.text == "" || p.subj_txt.text == "" || p.email_txt.text == "" || p.mess_txt.text == "") {
		// in any of the fields are missing
		// show error message and return false
		error_txt.text = "***All fields are required";
		return false;
	}
	_lv.name = p.name_txt.text;
	_lv.from = p.email_txt.text;
	_lv.subject = p.subj_txt.text;
	_lv.message = p.mess_txt.text;
	return true;
}
function sendForm() {
	if (validate()) {
		this._parent.email_lv.send('asp_mailer.asp');
	}
}
submit_btn.onRelease = sendForm;

```
