how to call javascript function
<p>when i click on the textbox which is inside the item template of gridview then onclick event should fire and then call the javascript function but my problem is that there no onclick event option in item template's textbox
plz hel p me.</p>

<pre><code>&lt;asp:GridView ID="GridView2" runat="server" AutoGenerateColumns="False" OnRowCommand="GridView2_RowCommand"
                Width="100%" GridLines="None" 
                style="font-family: Tahoma; font-size: xx-small" Font-Names="Tahoma" 
                Font-Size="XX-Small"&gt;
                &lt;Columns&gt;      
                    &lt;asp:BoundField HeaderText="Status" DataField="Status" HeaderStyle-HorizontalAlign="Left"
                        ItemStyle-HorizontalAlign="Left"&gt;
                        &lt;HeaderStyle HorizontalAlign="Left"&gt;&lt;/HeaderStyle&gt;
                        &lt;ItemStyle HorizontalAlign="Left"&gt;&lt;/ItemStyle&gt;
                    &lt;/asp:BoundField&gt;
                    &lt;asp:TemplateField HeaderText="Order" &gt;
                    &lt;ItemTemplate&gt;
                    &lt;asp:TextBox ID="TextBox1" Text='&lt;%#Eval("ArticleOrder")%&gt;' ReadOnly="true"  
                            runat="server" Height="18px" Width="16px" onclick="hello();" &gt;
                            &lt;/asp:TextBox&gt;
                    &lt;/ItemTemplate&gt;                           
                        &lt;HeaderStyle HorizontalAlign="Left" /&gt;
                    &lt;/asp:TemplateField&gt;
                    &lt;%--&lt;asp:BoundField HeaderText="Order" DataField="ArticleOrder" HeaderStyle-HorizontalAlign="Center"
                        ItemStyle-HorizontalAlign="Center"&gt;
                        &lt;HeaderStyle HorizontalAlign="Center"&gt;&lt;/HeaderStyle&gt;
                        &lt;ItemStyle HorizontalAlign="Center"&gt;&lt;/ItemStyle&gt;
                    &lt;/asp:BoundField&gt;--%&gt;
                    &lt;asp:BoundField HeaderText="Title" DataField="ArticleTitle" HeaderStyle-HorizontalAlign="Left"
                        ItemStyle-HorizontalAlign="Left"&gt;
                        &lt;HeaderStyle HorizontalAlign="Left"&gt;&lt;/HeaderStyle&gt;
                        &lt;ItemStyle HorizontalAlign="Left"&gt;&lt;/ItemStyle&gt;
                    &lt;/asp:BoundField&gt;
                    &lt;asp:TemplateField HeaderText="Edit" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center"&gt;
                        &lt;ItemTemplate&gt;
                            &lt;asp:ImageButton ID="ImageButtonedt" runat="server" ImageUrl="~/images/newspaper_go.png"
                                CommandName="edt" CommandArgument='&lt;%#Eval("ArticleID")%&gt;' /&gt;
                        &lt;/ItemTemplate&gt;
                        &lt;HeaderStyle HorizontalAlign="Center"&gt;&lt;/HeaderStyle&gt;
                        &lt;ItemStyle HorizontalAlign="Center"&gt;&lt;/ItemStyle&gt;
                    &lt;/asp:TemplateField&gt;
                    &lt;asp:TemplateField HeaderText="Delete" HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center"&gt;
                        &lt;ItemTemplate&gt;
                            &lt;asp:ImageButton ID="ImageButtondel" runat="server" ImageUrl="~/images/newspaper_delete.png"
                                CommandName="del" OnClientClick='return confirm("Are you sure you want to delete ?");' CommandArgument='&lt;%#Eval("ArticleID")%&gt;' /&gt;
                        &lt;/ItemTemplate&gt;
                        &lt;HeaderStyle HorizontalAlign="Center"&gt;&lt;/HeaderStyle&gt;
                        &lt;ItemStyle HorizontalAlign="Center"&gt;&lt;/ItemStyle&gt;
                    &lt;/asp:TemplateField&gt;
                &lt;/Columns&gt;
            &lt;/asp:GridView&gt;
</code></pre>

<p>javascript function:</p>

<pre><code>hello()
{
var divName = document.getElementById('div1');
        var divFade = document.getElementById('fade');
        divName.style.display = 'block';
        divFade.style.display = 'block';
}  
</code></pre>
