Datalist

B

brian

I have a datalist bound to a dataset using SQL server
2000.

There is 1 button in the datalist and the buttons text
property is bound in the databinding properties.

How can I find the text of the button in the code behind?

I have tried e.item.findcontrol("txtName", Button).text
but get an error saying "button is a type and can't be
used as an expression"

I have also tried using CTYPE.

Currently it is being assigned to a string datatype but I
have also tried assigning it to a control type.

Thanks for any suggestions
 
B

brian

Thanks but I figured it out. I had the wrong format for
findcontrol. It should have been e.item.findcontrol
("txtName"), button).text. I didn't have the ')' at the
end of "txtName".

Once again thanks for all the support this group has
given me.
 

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

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,818
Latest member
Brigette36

Latest Threads

Top