This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > Dreamweaver > April 2005 > undefined message and not a value





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author undefined message and not a value
Rani

2005-04-30, 7:17 pm

can anyone tell me why am i getting undefined and not a value for var drtw
and why nothing happens when i call docalc function ?


<body>
<script language="JavaScript">
var drbbw;
var drtw;

function doCalc() {
var drtw =" 0";
}
</Script>





<td align="center" valign="middle"><input type="text" name="drbbw" size=1
onchange="doCalc()">

<script type="text/javascript"><!--
document.write(drtw); //--></script>

</body>
</html>


Mick White

2005-04-30, 7:17 pm

http://www.mickweb.com/demo/mult.html

Mick

Rani wrote:

> can anyone tell me why am i getting undefined and not a value for var drtw
> and why nothing happens when i call docalc function ?
>
>
> <body>
> <script language="JavaScript">
> var drbbw;
> var drtw;
>
> function doCalc() {
> var drtw =" 0";
> }
> </Script>
>
>
>
>
>
> <td align="center" valign="middle"><input type="text" name="drbbw" size=1
> onchange="doCalc()">
>
> <script type="text/javascript"><!--
> document.write(drtw); //--></script>
>
> </body>
> </html>
>
>

Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews