<!--- This example shows Val --->

<HTML>

<HEAD>
<TITLE>
Val Example
</TITLE>
</HEAD>

<BASEFONT FACE="Arial, Helvetica" SIZE=2>
<BODY  bgcolor="#FFFFD5">

<H3>Val Example</H3>


<CFIF IsDefined("form.theTestValue")>

	<CFIF Val(form.theTestValue) is not 0>
	<H3>The string <CFOUTPUT>#DE(form.theTestValue)#</CFOUTPUT> can be converted to a number:
	<CFOUTPUT>#Val(form.theTestValue)#</CFOUTPUT></H3>
	<CFELSE>
	<H3>The beginning of the string <CFOUTPUT>#DE(form.theTestValue)#</CFOUTPUT> cannot be converted to a number</H3>

	</CFIF>


</CFIF>

<FORM ACTION="val.cfm" METHOD="POST">
<P>Enter a string, and discover if
its beginning can be evaluated to a numeric value.

<P><INPUT TYPE="Text" NAME="TheTestValue" VALUE="123Boy">

<INPUT TYPE="Submit" VALUE="Is the beginning numeric?" NAME="">


</FORM>





</BODY>

</HTML>       
