[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.dotnet.framework.aspnet.webcontrols

Issue with LinkButton not rendering an HREF attribute

John Michael Palermo IV

1/4/2003 3:16:00 AM

Help!

I am creating a custom server control which instantiates and renders a
DataGrid control. In the DataGrid control, if I set either the
AllowPaging or AllowSorting to true, it is suppose to render LinkButtons
for the column headers (for sorting) and the paging links.

When the server control is rendered, I can see the text of the
LinkButtons, but there is no "linking" capabilities. When I view the
source of the page, I see the <a> tags with no HREF attribute!

I have tried to explicity add LinkButton controls when the ItemDataBound
event is triggered to ListItemType.Header items. I get the same result
-- <a> tags with no HREF attributes?

Has anyone ever ran into this?

----
J. Michael Palermo IV
j.michael@palermo4.com
----

*** Sent via Developersdex http://www.develop... ***
Don't just participate in USENET...get rewarded for it!
1 Answer

John Michael Palermo IV

1/4/2003 5:03:00 AM

0

I would like to add more information from the previous post...

First of all, the issue is not related to the DataGrid, as I have tried
to simply create a custom server control which wraps around a LinkButton
- and I still have the same issue.

If the LinkButton did render correctly, it would have an HREF attribute
pointing to the __doPostBack client-side function. From what I can see,
when the custom server control is rendered, it does not emit the
__doPostBack script. Is this possibly why the HREF is not included?

Please help!

----
J. Michael Palermo IV
j.michael@palermo4.com
----

*** Sent via Developersdex http://www.develop... ***
Don't just participate in USENET...get rewarded for it!