Skip to content
October 3, 2012 / kiranpatils

Basics of Publishing multiple items programmatically


So long back posted one problem on SDN forum —

We have one functionality where users can select multiple items from different path for example :


Basically, we wanted to publish multiple items in one publishing Job. We asked to Sitecore support guys and they said:

In the comment for your forum post #45665 it completely correctly noted that currently in the Sitecore CMS you can publish either a single item or a whole subtree — not a list of items. You may want to use incremental publishing instead of smart publishing, because it publishes only recently changed items.

Using an incremental publishing was not an option for us. As we have Multisite Sitecore solution.


Also, Sitecore support team suggested to use  Alex Shyba’s concept:

Where we add item references programmatically. John is also fine with this approach on this thread :

So, you can also use it. But with few suggestions:

1.  It may affect performance. So, please test it throughly.

2. If you are using Multisite solution and have custom HTML cache clearing handler on publish:end:remote then make sure that you added same site’s items in one publish job.

Happy Multiple items publishing via code! 🙂



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: