Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Controls > Extending WebControl - PropertyGrid to hold LinkButton

Thread Tools

Extending WebControl - PropertyGrid to hold LinkButton

Posts: n/a
Hi there,

I am trying to inherit from an existing webcontrol, however I want to add a
property to the control that will be exposable in the property grid. The
property in question has a type of LinkButton. I want to define the
LinkButton that this control must use(I want to hook it's click event up) at
design time. However I'm having problems with setting it. The property
appears, and lists any current LinkButtons on my webform in a dropdown list,
which is great, but when I select a value, I get the following error similar

"System.Web.HttpParseException: Cannot create an object of type
'System.Web.UI.WebControls.LinkButton' from its string representation
'linkButtonGo' for the 'GoButton' property."

I think I have to implement a TypeConverter or something along those lines,
but I haven't had any success with that becasue quite frankly im not too sure
exaclty what I need to do to prevent this exception. Can someone please help
me out here?

Thanks in advance,
Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Linkbutton does not look like a linkbutton Sathyaish ASP .Net 3 09-08-2005 09:41 AM
Linkbutton does not look like a linkbutton Sathyaish ASP .Net Datagrid Control 1 09-08-2005 08:44 AM
PropertyGrid-Need HELP =?Utf-8?B?RGVlcGFr?= ASP .Net 2 07-15-2005 08:40 AM
LinkButton Inherited from WebControl problem? Dave ASP .Net Web Controls 1 06-23-2004 06:53 PM
PropertyGrid - ReadOnly Dave Wurtz ASP .Net 2 11-14-2003 04:55 PM