Skip to main content
edited body; edited title
Source Link

How to determine type of schemaSchema?

I am trying retrieve a list of Normal and Multimedia schemasSchemas from a given publicationPublication context. So far I have:

RepositoryItemsFilter filter = new RepositoryItemsFilter(engine.GetSession());
filter.ItemTypes = new ItemType[] { ItemType.Schema };
filter.Recursive = true;

Publication pub = this.GetPublication();
foreach (Schema schema in pub.GetItems(filter))
{
    //need to further refine to only use Normal and MM schemas
}

This is usually not a problem when we are working with a componentComponent because we just do ComponentType.Normal or ComponentType.Multimedia. But how do we do this if we only have a Schema?

How to determine type of schema?

I am trying retrieve a list of Normal and Multimedia schemas from a given publication context. So far I have:

RepositoryItemsFilter filter = new RepositoryItemsFilter(engine.GetSession());
filter.ItemTypes = new ItemType[] { ItemType.Schema };
filter.Recursive = true;

Publication pub = this.GetPublication();
foreach (Schema schema in pub.GetItems(filter))
{
    //need to further refine to only use Normal and MM schemas
}

This is usually not a problem when we are working with a component because we just do ComponentType.Normal or ComponentType.Multimedia. But how do we do this if we only have a Schema?

How to determine type of Schema?

I am trying retrieve a list of Normal and Multimedia Schemas from a given Publication context. So far I have:

RepositoryItemsFilter filter = new RepositoryItemsFilter(engine.GetSession());
filter.ItemTypes = new ItemType[] { ItemType.Schema };
filter.Recursive = true;

Publication pub = this.GetPublication();
foreach (Schema schema in pub.GetItems(filter))
{
    //need to further refine to only use Normal and MM schemas
}

This is usually not a problem when we are working with a Component because we just do ComponentType.Normal or ComponentType.Multimedia. But how do we do this if we only have a Schema?

grammar
Source Link
Glenn Stevens
  • 1.9k
  • 2
  • 18
  • 33

I am trying retrieve a list of Normal and Multimedia schemas from a given publication context. So far I gothave:

RepositoryItemsFilter filter = new RepositoryItemsFilter(engine.GetSession());
filter.ItemTypes = new ItemType[] { ItemType.Schema };
filter.Recursive = true;

Publication pub = this.GetPublication();
foreach (Schema schema in pub.GetItems(filter))
{
    //need to further refine to only use Normal and MM schemas
}

This is usually not a problem when we are working with a component because we just do ComponentType.Normal or ComponentType.Multimedia. But how do we do this if we only have a Schema?

I am trying retrieve a list of Normal and Multimedia schemas from a given publication context. So far I got:

RepositoryItemsFilter filter = new RepositoryItemsFilter(engine.GetSession());
filter.ItemTypes = new ItemType[] { ItemType.Schema };
filter.Recursive = true;

Publication pub = this.GetPublication();
foreach (Schema schema in pub.GetItems(filter))
{
    //need to further refine to only use Normal and MM schemas
}

This is usually not a problem when we are working with a component because we just do ComponentType.Normal or ComponentType.Multimedia. But how do we do this if we only have a Schema?

I am trying retrieve a list of Normal and Multimedia schemas from a given publication context. So far I have:

RepositoryItemsFilter filter = new RepositoryItemsFilter(engine.GetSession());
filter.ItemTypes = new ItemType[] { ItemType.Schema };
filter.Recursive = true;

Publication pub = this.GetPublication();
foreach (Schema schema in pub.GetItems(filter))
{
    //need to further refine to only use Normal and MM schemas
}

This is usually not a problem when we are working with a component because we just do ComponentType.Normal or ComponentType.Multimedia. But how do we do this if we only have a Schema?

Tweeted twitter.com/#!/StackTridion/status/354297143013552131
Source Link
Nickoli Roussakov
  • 18.4k
  • 4
  • 31
  • 62

How to determine type of schema?

I am trying retrieve a list of Normal and Multimedia schemas from a given publication context. So far I got:

RepositoryItemsFilter filter = new RepositoryItemsFilter(engine.GetSession());
filter.ItemTypes = new ItemType[] { ItemType.Schema };
filter.Recursive = true;

Publication pub = this.GetPublication();
foreach (Schema schema in pub.GetItems(filter))
{
    //need to further refine to only use Normal and MM schemas
}

This is usually not a problem when we are working with a component because we just do ComponentType.Normal or ComponentType.Multimedia. But how do we do this if we only have a Schema?