Hi all!
I have a PageList and it lists propertys from child pages, like this.
<itemTemplate>
<%# Container.CurrentPage["EventDate"] %>
</itemTemplate>
Now, if the editor havent written anything in the property on the child's page type I dont want it to be written on the page. So, I tried
<% if (Container.CurrentPage["EventDate"] != null) { %>
<%# Container.CurrentPage["EventDate"] %>
<% } %>
But that doesnt work. Neither does (because it is always null)
<% if (CurrentPage["EventDate"] != null) { %>
<%# Container.CurrentPage["EventDate"] %>
<% } %>
How do I solve it? And please, as easy as possible! =) Thank you very much.