Showing posts with label Visual Studio 2010. Show all posts
Showing posts with label Visual Studio 2010. Show all posts

Saturday, July 16, 2011

Activate only selected features while deploying a solution package in Visual Studio 2010

In Visual Studio 2010 SharePoint Developer Tools is what we use to develop quick solutions to SharePoint. With these tools we can quickly deploy into SharePoint environment as well. But, the only issue we see here is, if we are trying to deploy a package which contains a set of 5 features then all of them will be activated by default. But, this might not be a valid behavior for us. We need to activate only 3 features while deploying the package and the other 2 features need to be installed into SharePoint but should not be activated. So, this is not available by default in the SharePoint Development Tools in Visual Studio 2010.

Recently when I was browsing in internet for this, how to deploy only selected features into SharePoint, but not all and found a great Visual Studio 2010 Extension. Which is a great tool to use and works perfect.

Download the extension here.

Once you get his extension, directly run it by double clicking on it. Before you see the changes, close any existing Visual Studio instances and reopen them. The extension will be added to Visual Studio 2010 and ready to use. But, to use it in your SharePoint project, you need to do one more exercise.

Saturday, July 2, 2011

Error occurred in deployment step ‘Recycle IIS Application Pool’: The communication object, System.ServiceModel.InstanceContext, cannot be used for communication because it has been Aborted

When we are developing custom code through Visual Studio 2010 for SharePoint 2010 sites and when we try to deploy the solution then we might see the below error.

"Error occurred in deployment step ‘Recycle IIS Application Pool’: The communication object, System.ServiceModel.InstanceContext, cannot be used for communication because it has been Aborted."

When I see this very first time and did not get any clue of what it is looking for and why it is not able to communicate to SharePoint sites. After doing some trail and error methods and checking Event Viewer, Logs etc... failed in all the ways in deploying the custom piece to SharePoint. Finally, a simple solution worked but didn't find any reason what is the main issue!

Solution:
  1. Sometimes when I do rebuild the project and deploy directly without doing "Package" from Visual Studio it is successful. 
  2. If it is not successful then the only way I see is RESTART your visual studio and deploy.
  3. (From below comments: ) Restarting "Windows Management Instrument" service will work. (I haven't tested).
Frustrated hours come to an end... There is some way always to make our life go smooth! Happy programming.

Friday, July 16, 2010

More SharePoint 2010 templates in Visual Studio 2010

I am working on SharePoint 2010 these days and all the development is on Visual Studio 2010. The IDE is very cool and great features. Really very helpful for developers and administrators as everything is builtin like deploy, configure and easy development. I really love it. There are plenty of SharePoint 2010 templates are available by default in Visual Studio. Here are some from Microsoft with extra templates. Install them and use them for time saving and learn more...
http://code.msdn.microsoft.com/vsixforsp

Wednesday, June 23, 2010

SharePoint 2010 ECMAScript Intellisense in Visual Studio 2010

This post is a very big help to the SharePoint 2010 developers. We need the intellisense help to write code fast in our SharePoint applications. But, in SP2010 BETA I faced so many problems to find what methods a java script object has. After written a long post on how to get the java script intellisense working in Visual Studio 2008 this is now an easy for me to do the same on Visual Studio 2010. I just tried the same implementation in VS 2010 and that worked great. So, there I started and started using it in ECMAScript development. When I first see the intellisense working in VS 2010 felt very very happy and jumped into the air. Because, before to find the same methods in the ECMAScript object, I had wasted hours and hours. One of the example is this post "How to know all methods in SP object".

Solution:
By using reference tag everything possible.

Sunday, March 14, 2010

Fix for Not able to connect to SharePoint 2010 server web sites through Visual Studio 2010

Today, I started working on SharePoint 2010 server side object model to delete all the files from the document library using batch command. I have written all the code but, I failed to connect to the web site using SPSite class. I tried all combination like with server name, ip address and many more. Always I am getting the exception that "not able to connect to SharePoint site".
This is the actual exception :
"The Web application at http://nb16 could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing content, the system administrator may need to add a new request URL mapping to the intended application."

Wednesday, October 21, 2009

Visual Studio 2010 BETA 2, Download now

Visual Studio 2010 BETA 2 is released. Get it and start researching on new things added in this version. We know it has more features and explorers in it and lot of options to simplify and faster development and .NET 4.0. So, why to wait. Get some time and download it now.

http://msdn.microsoft.com/en-us/vstudio/default.aspx

Saturday, June 6, 2009

Microsoft Visual Studio 2010 – The great IDE in the IT world

Visual Studio 2010. wow!!! Lot of features. What a product from Microsoft. It has almost everything integrated for developing all technologies related to ASP.NET like Silverlight, ASP.NET, SharePoint, WPF and QA related. The version of ASP.NET supporting is framework 4.0. This is again a big change.
We will take a look at the features available in the Visual Studio 2010.
First I am a SharePoint guy, so I will start from SharePoint tools available in Visual Studio 2010.
  • Till now, we have an option to add a new item for ASPX, ASCX, CSS, JS, Cs etc… Now we have an option to add a new web part project item and the Visual web part designer which loads a user control as a web part for SharePoint. Wow, how cool it is! Pretty much good.
  • We have another fantastic facility for adding an event receiver for SharePoint List/Library/Site and using the wizard to choose the event receiver type. From this, it will create a source file with that event receiver. [Again no need of creating a special project and write everything manually.]
  • A special explorer window which will pull information from the SharePoint sites like Lists, Libraries and other artifacts in SharePoint directly inside of Visual Studio when connected to a SharePoint site. It just like what we are seeing the team explorer in Visual Studio 2005/2008 when connected to Team Foundation server.
  • We have a package explorer to configure WSP files, feature files and other package related files in SharePoint. This is good thinking by the team to keep track of all the solution we are using in a SharePoint site at one place. The key F5 will compile, build, debug and deploy the solution to the specific site or farm depending on the configuration.
  • Till now if you want to create a SharePoint custom workflow we used to create a C# SharePoint workflow project and configure manually to implement it. But now, in this version they have added an ASPX workflow initiation form to a workflow project.
  • We already know about the WSP builder. From which we can create the solution file easily without doing any extra configurations etc, etc. Visual Studio 2010 includes the WSP file import to create a new solution automatically.
Second, I like Silverlight technology and development. I will explain the Silverlight features available in Visual Studio 2010.
  • While creating a Silverlight project you have an option to select the Silverlight version like 2.0 or 3.0
  • A good and great news for Silverlight developers that Visual Studio 2010 supports for both Silverlight development and editable design surface. WOW!!! this is the best and great feature. Isn’t it? [Thanks to Microsoft. When i am developing Silverlight application I am always having a thought that why MS VS team didn't give option to edit the Silverlight objects in editor inside Visual Studio. If I need to edit any thing I always need to go to Microsoft Expression Blend. But now editor is available inside it.]
  • More features available with Silverlight 3.0 in Visual Studio 2010. We will discuss this in upcoming blog posts.
Another feature that Visual Studio 2010 is integrated a great module for testing [QA].  You can take a look at it here.

The final feature is very cool feature that the new look for Visual Studio 2010. Very good rich and cool UI and very good user experience. I will come with another post that will give you good information about it with nice screen shots.

I think this information will help you to understand the features about Visual Studio in different scenarios. Keep an eye on the blog for more updates.