Try Now
More in this section

Forums / Developing with Sitefinity / Guid of generic_content

Guid of generic_content

2 posts, 0 answered
  1. Paul
    Paul avatar
    176 posts
    18 Nov 2008
    17 Apr 2009
    Link to this post


    I need to get Guid of Generic Content and show It in details when preview item.

    How can I do this?

  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    16 Jun 2017
    17 Apr 2009
    Link to this post
    Hello Paul,

    Here is an sample how to get the Guid of a certain content item.

    ContentManager manager = new ContentManager(); 
            IList ListAllItems = manager.GetContent(); 
            foreach (IContent cont in ListAllItems) 
                if (cont.GetMetaData("Title") == "Mycontent"

    Best wishes,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
2 posts, 0 answered