Can I add tooltiptext to a select button in a datagrd?

S

Stevie_mac

Yes, in ItemDataBound, get a reference to the button & just do it!

Dim b as Button
b = CType(e.Item.Cells(0).Controls(1), Button)
b.ToolTip = "Tooltip created at " & Now.ToString()

Sample assumes button is in 1st column & is 2nd item in column (as a button
would be in a tempate column since it gets wrapped in a 'literal' (ie DIV))
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,581
Members
45,056
Latest member
GlycogenSupporthealth

Latest Threads

Top