|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
how to trigger event with HtmlInputButton?Hi,
I created a HtmlInputButton in the code-behind of a asp.net application like this: Dim bt As HtmlInputButton bt = New HtmlInputButton bt.ID = "bt1" frm.Controls.Add(bt) But there is no 'click' or 'onclick' or 'onclientclick' property. I see it but of course nothing happen when clicking on it. How can i link a function in Javascript to that button. Thanks Britt Britt,
You just add an attribute to your button: bt.Attributes.Add("onclick", "your_javascript") HTH Show quoteHide quote "Britt" wrote: > Hi, > > I created a HtmlInputButton in the code-behind of a asp.net application like > this: > Dim bt As HtmlInputButton > bt = New HtmlInputButton > bt.ID = "bt1" > frm.Controls.Add(bt) > > But there is no 'click' or 'onclick' or 'onclientclick' property. I see it > but of course nothing happen when clicking on it. > How can i link a function in Javascript to that button. > > Thanks > Britt > > > Thanks Sergey
"Sergey Poberezovskiy" <SergeyPoberezovs***@discussions.microsoft.com> schreef in bericht Show quoteHide quote news:CA6046E5-BD6D-4FA1-8485-785F575C42D6@microsoft.com... > Britt, > > You just add an attribute to your button: > bt.Attributes.Add("onclick", "your_javascript") > > HTH > "Britt" wrote: > >> Hi, >> >> I created a HtmlInputButton in the code-behind of a asp.net application >> like >> this: >> Dim bt As HtmlInputButton >> bt = New HtmlInputButton >> bt.ID = "bt1" >> frm.Controls.Add(bt) >> >> But there is no 'click' or 'onclick' or 'onclientclick' property. I see >> it >> but of course nothing happen when clicking on it. >> How can i link a function in Javascript to that button. >> >> Thanks >> Britt >> >> >>
Re: ActiveX raise event - attn Walter Wang
Selecting a single node in 'XML' More than one method is found with VB but not with C# Graph control webreq.getresponse exceptions Application.StartupPath turn off assertions in VB 2005 Adding a Web Reference into a Windows Project How to read XML from a string variable?? Use dll created in dotnet using them from vb6 |
|||||||||||||||||||||||