Tag Info

New answers tagged

0

You may want to rephrase your question. I am not sure what your end goal is, but if it is to use a term set to navigate through your site, then watch this video: https://www.youtube.com/watch?v=7ICmKCSGS7M


0

For client side cascading drop downs, I use SPServices. If you aren't familiar with it here is a link to the SPCascadeDropdowns. For this you will have to have your cascading structure defined in lists with lookup fields. After you set that up it's fairly straight forward. Here's a couple more resources on how to use SPServices and cascading drop downs: ...


0

There is a workaround to get the (C#) CSOM to work in a farm solution (the name for solutions that encompass code that needs to be installed on the server), there is an SP StackExchange answer on that here: CSOM in FarmSolution You could also use a Sandbox solution as you mentioned; C# code in sandbox solutions is deprecated but you could create a webpart ...


0

I'm not entirely sure what you're asking, but I'm going to assume you are having trouble figuring out where the code you've pasted here is supposed to go. The link you've provided suggests that you add it to the Codebehind for the pagelayout.ASPX that you are creating. This link explains how to add a codebehind file to an ASPX page:


1

No, there is no way to deploy a solution to a particular site collection. A solution is deployed either Globally to all web applications or a single web application. It is the feature inside the solution which can be deployed to a farm/webapplication/site collection/web.


1

Usually you deploy your farm solution to web application, but you activate solution's feature(s) only on desired site collection.


0

To access the list in Parent site from the subiste we can check the based on the condition of current web url: String siteUrl = SPContext.Current.Web.Url; //Fetch the top site url //Fetch the top site url if it is any subsite if ( siteUrl.ToLower().Contains("/blog") ) { siteUrl = SPContext.Current.Web.ParentWeb.Url; }


0

i think you might be getting confused ;) SPContext.Current.Web.ParentWeb.Url is fine if you do: SPContext.Current.Web.RootWeb.Url root web is the web at the root level (top most level) of the site collection! if its at root which i think your refering to??: SPWeb web = SPContext.Current.Web.RootWeb //you are now in the root parent spweb object ...


1

You should get the current site collection rootweb url as below String siteUrl = SPContext.Current.Site.RootWeb.Url;



Top 50 recent answers are included