CRM Plugin deployment - dynamics-crm-2011

I have created a crm plug library (dll) and then added this dll to CRM package for deployment.
I want to add 6- 7 steps for plugin.
1) Is there is any way to added steps for plugin using visual studio. We can do using plugin registration tool.
2) How to debug the plugin. (onpremise and crm online)

If you install the Developer Toolkit available in the CRM SDK you'll get a range of tooling added to Visual Studio that includes the ability to develop and deploy all the main CRM 2011 assets including plugins, workflows, web resources etc. As of the latest SDK release the tooling now supports Visual Studio 2010 and 2012 via separate installers.
A key part of the tooling is the CRM Explorer that gets integrated into Visual Studio. From this you can browse all of the entities within an organisation and generate stub code for plugins directly within Visual Studio. Once the plugin has been deployed you can then use the CRM Explorer to add additional steps.
The SDK has a good README included in the install folder for the toolkit. Have a read of that.
To debug plugins on-premise, if running CRM locally you need to attach to w3wp.exe if running without isolation otherwise attach to the sandbox process (the full name of the process eludes me). The toolkit makes debugging easier as it ensures your PDB files are available.
You can't debug plugins deployed to CRM Online.

You can register if you build your own registation tool, directly with visual studio you can't.
See here a resume how debug a plugin in all configuration situations (online, offline, sandbox or asynchronous registered plug-ins).
See here how debug with registation tool.
See here how remote debug.
See here to debug crm online, using ITracingService, isn't step by step but is useful to debug.

Related

Emptying IIS website before automatic web deployment from TFS 2012

I'm automatically publishing a web project after build from TFS 2012 by using a publishing profile (I have a build definition on TFS that has /p:DeployOnBuild,PublishProfile... etc. as additional MSBuild arguments). Everything works fine. However, since my web site creates some temporary local folders I'd like to clean up before the next automatic deployment. Is there a way to easily clean up? Maybe some additional MSBuild argument?
You should switch to using Release Management for Visual Studio 2013. I have had it Woking fore more than one customer with 2012. You can then create orchestration that is specifically designed for deployment rather than compilation.
Release Management with Visual Studio 2013

How to register Performance Counters Manifest using VS2008 Installer

I have a VC++ (unmanaged) project to which I added performance counters using manifest method. Everything is working great and I even have build steps that do manifest compilation and automatic registration using lodctr.exe tool with /m:manifest switch.
The problem that I'm running into is that I now need to make installer (VS2008 Installer project) do registration on install (unregistration on uninstall).
I tried to set it up by having a custom action that referenced lodctr.exe tool with CustomActionData set to /m:[TARGETDIR]PerfMon.manifest and similar setup using unlodctr.exe for custom uninstall action.
When installer runs, I do see a brief flash of cmd window (which is ok), but counters are not getting registered. I ran SysInternals' ProcMon tool, and I don't see lodctr.exe process even created.
I tested that running lodctr.exe manually on target machine registers the counters.
I googled for an example or explanation how to do it with Visual Studio installer project, but came up empty. It has some .NET oriented examples, but nothing for unmanaged, hard and cold VC++...
How can I register performance counters manifest using installer project?
Visual Studio installer project has very limited functionality. Starting from Visual Studio 2012 Visual Studio installer project is not supported, you should consider to use Windows Installer XML (WIX) instead.
Include your manifest into WIX project and use WIX's PerfCounterManifest with it.

Install custom tool using VSIX without running devenv /setup

I have created a custom tool within a Visual Studio 2012 "Package" project and am distributing it via a .vsix file. Everything works great but the custom tool is not registered unless I run "devenv.exe /setup". Is there any way around this? I was under the impression (and it seems to be confirmed by the EF team) that this only needed to be done when installing using an MSI.

How to use PhoneGap with Visual Studio

I'm having trouble getting started with PhoneGap on windows 8, VS 2012, namely:
I don't know how to install the templates
I open the template projects I've downloaded from PhoneGap, but they are in compatible with VS2012
I don't know where to start in respect to creating my first simple CRUD application
I want to connect to a WCF API and make some calls
How to publish the result allowing installation on many devices:
I mainly want to use iPhone and Android devices
How do I get started with PhoneGap?
#Smithy, Microsoft just made it possible to develop Cordova apps with Visual Studio 2013 Update 2.
Its just a preview as far as I understand, but go have a look.
If you have the latest version of Visual Studio installed, you need to go to Microsoft'd download page and download the installer:
http://www.microsoft.com/en-us/download/details.aspx?id=42675
This comes along with documentation on how to get started and how to install and set it up in VS 2013.
Good luck.
UPDATE:
With the release of Visual Studio 2013 Community Edition along with Update 4, MS has made it easier than ever to create Cordova project....and best thing of all is it's FREE!!!!
Benefit is that if your used to VS like me, this is a comfortable environment, and its super easy to get started.
To get access to these templates, follow the steps when creating a new project in VS, and you will be prompted to install additional software, including but not limited to SDK Manager, adt, iTunes, emulators etc..
After these are installed, it is now simple to create projects, edit and run them in the included RIPPLE emulator.
These projects can also in addition be deployed to your device from VS.
To check if your device is picked up on your PC, open a cmd and run "adb devices" to see if your device is picked up on your PC and a list of connected devices.
Easy, effective and it works. From, see link on terms of use and limitations in organisations: Free Dev Tools
Download link here: http://www.visualstudio.com/en-gb/products/free-developer-offers-vs
Q: Who can use Visual Studio Community?
A: Here’s how individual developers can use Visual Studio Community:
Any individual developer can use Visual Studio Community to create their own free or paid apps.
Here’s how Visual Studio Community can be used in organizations:
An unlimited number of users within an organization can use Visual Studio Community for the following scenarios: in a classroom learning environment, for academic research, or for contributing to open source projects.
For all other usage scenarios: In non-enterprise organizations, up to 5 users can use Visual Studio Community. In enterprise organizations (meaning those with >250 PCs or > $1 Million US Dollars in annual revenue), no use is permitted beyond the open source, academic research, and classroom learning environment scenarios described above.
Thanks Microsoft!
You can use VS to edit the html, css, and javascript files, but I don't believe there are any VS project templates available. At least I've never seen any.
But, you won't be able to compile and deploy. The templates for Android for instance are eclipse project templates since phonegap is building a java application in order to deploy to android.
If you want to develop for android, follow the getting started guide from Phonegap ( I can't get you a link right now due to firewall issues). The files you put in the www folder will be the html, css, and javascript files for your project and you can use anything you want to edit them, including VS.
You can create PhoneGap application using
Cordova vs plugin
Telerik App Builder
vsnomad
for more information please see the below link
http://sourcefreeze.com/cross-platform/visual-studio-cordova-plugins-for-cross-platform-mobile-apps/
You may also want to refer to this post that describes how to use Phonegap projects in the new Multi-Device Hybrid Apps that uses Cordova integration in VS - https://stackoverflow.com/a/23621633/1277291
RedGate has a product called Nomad which integrates beautifully with Visual Studio 2013.
It makes use of the PhoneGap Build cloud service. With this approach you don't need all the platform SDK's on your system. Works very well.
See this video. Unfortunately RedGate recently stopped supporting Nomad. I'm hoping Microsoft's new offering will offer similar capability.

Clickonce Deployment after add a report with visual studio 2012

I have a c# application that publishes to a server using click-once, so our company clients can run it. I upgrade my visual studio from 2010 to 2012. every thing is great so far and clients can run the application normally after my publishes.
then I add a report viewer Item to my application and it runs on my pc well. but after publishing the clients face this error:
unable to install or run the application. the application requires that assembly microsoft.reportviewer.ProcessingObjectModel version 11.0.0.0 to be installed in your GAC.
what should I do now, I search a lot but cant find a solution.
thanks.
You will need to add the report viewer as a prerequisite. Here is a link to MSDN that describes what is needed.
http://msdn.microsoft.com/en-us/library/ms251723.aspx

Resources