<div>Hey </div>  <div>&nbsp;</div>  <div>Yes the function does get called. The whole code&nbsp;actually works fine when we tried somewhere else as a normal HTML but as an OME .tmpl file it doesn't...</div>  <div>&nbsp;</div>  <div>Thanks for your help<BR><BR><BR><B><I>august &lt;august@develop.ment.org&gt;</I></B> wrote:</div>  <BLOCKQUOTE class=replbq style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #1010ff 2px solid">&gt; This javascript code works fine but when we pasted it<BR>&gt; in one of the .tmpl file for OME it doesn't.<BR>&gt; Any ideas?<BR><BR>With javascript in webbrowsers, there is practically unlimited<BR>possibilities for things to go wrong.<BR><BR>Where are things going wrong?<BR><BR>First, are you sure that the function "addColumn" is being called at<BR>all?<BR><BR>Just put an "alert('hello')" in there and see if that gets called when<BR>you click the button. If not, then you might have to put the script<BR>declaration somewhere else, perhaps after
 the form declaration.<BR><BR>Also, if the script is called and the problem is elsewhere, it might be<BR>that "workset" is inside a 'div' or some other element and the path is<BR>wrong. so, instead you might try:<BR><BR>hi = document.forms['workset'].column1_name.value;<BR><BR>-august.<BR><BR><BR>&gt; <BR>&gt; Thanks.<BR>&gt; <BR>&gt;  <SCRIPT type=text/javascript><br>> <br>> function addColumn(workset)<br>> {<br>>     hi = document.workset.column1_name.value;<br>>     alert("Hi" + hi);<br>> }<br>> <br>> </SCRIPT>   <BR>&gt; <BR>&gt;   <FORM name=workset><BR>&gt; <INPUT id=yid <br>&gt; name="column1_name"&gt;<BR>&gt; <INPUT type=button value="Add Column" <br>&gt; onClick="addColumn(workset)"&gt;<BR>&gt; </FORM><BR><BR></BLOCKQUOTE><BR><p>&#32;Send instant messages to your online friends http://au.messenger.yahoo.com