forum855 would be a better place to post this.
however what you have posted above will not work. attributes refer to client attributes (js, css, html) your code is server code, which knows nothing about the client.
hyperlinks are not buttons this is by design. instead use a LinkButton (looks like a link behaves like a button).
use the asp.net server control properties whenever possible and avoid the Attributes.Add(); this will make debugging much easier.
Jason Meckley
Programmer
Specialty Bakers, Inc.