Ask a Question related to ASP.NET Building Controls, Design and Development.
-
paul.hester@gmail.com #1
Literal control rendering empty
Hi all,
I have a custom control with an overridden Render method. Inside this
method I'm rendering each control in its collection using their
RenderControl method. However, I'm running into a problem in this
scenario:
<myprefix:mycontrol runat="server">
<%= SomeVariable %>
</myprefix:mycontrol>
The contained control is showing up in the control collection as a
LiteralControl, but its Text property is empty. Well, it's a series of
spaces, so it's not showing up with any content. I can put <%=
SomeVariable %> anywhere outside my custom control and it will render
the variable value correctly.
Is there anything I can do to ensure the variable value is rendered?
I hope this post makes sense!
Thanks,
Paul
paul.hester@gmail.com Guest
-
Custom Control rendering
I'm overriding the Render method in a Custom Control that inherits from WebControl. Some of the ouput code is as follows; protected override void... -
Ignore literal content when parsing custom control children?
Hi, I'm sure this has been asked before... Is there a setting or attribute that I can specify on my control to tell the page parser to ignore... -
Problem overriding render method to format literal content of nested tags in custom control
Peter, I was under the mistaken impression that I was already overriding CreateChildControls to create the controls with the code: protected... -
rendering derived control from composite control
I am triing to load a control derived from a datagrid into a composite control so I can wrap some html around the datagrid. it renders the html in... -
Rendering non-composit Control
Hello NG I'm a newbie with programming controls and this seems to me a very easy question: I had create a non composit control. Inherit from... -
Alessandro Zifiglio #2
Re: Literal control rendering empty
hi Paul, in case you missed my response to this same post on WebControls
group, here it is :
[url]http://groups.google.com/group/microsoft.public.dotnet.framework.aspnet.webcontro ls/browse_thread/thread/b798035825291755/c1a49e17579eb197?lnk=st&q=&rnum=1&hl=en[/url]
Regards,
Alessandro Zifiglio
[url]http://www.AsyncUI.net[/url]
<paul.hester@gmail.com> ha scritto nel messaggio
news:1154297655.410091.153990@b28g2000cwb.googlegr oups.com...> Hi all,
>
> I have a custom control with an overridden Render method. Inside this
> method I'm rendering each control in its collection using their
> RenderControl method. However, I'm running into a problem in this
> scenario:
>
> <myprefix:mycontrol runat="server">
> <%= SomeVariable %>
> </myprefix:mycontrol>
>
> The contained control is showing up in the control collection as a
> LiteralControl, but its Text property is empty. Well, it's a series of
> spaces, so it's not showing up with any content. I can put <%=
> SomeVariable %> anywhere outside my custom control and it will render
> the variable value correctly.
>
> Is there anything I can do to ensure the variable value is rendered?
>
> I hope this post makes sense!
>
> Thanks,
>
> Paul
>
Alessandro Zifiglio Guest



Reply With Quote

