Wednesday, December 29, 2010

Microsoft Dynamics CRM 2011

Here is some of the pondering thoughts for exporting and Importing options provided in CRM2011.

Concept of Solution in 2011:
Think of this way, a Solution is a container for the following items:
1. Custom Entities
2. Plugins
3. Customizations
4. Web Resources (May be Images, JavaScript files etc...)

There are two types of solution:
• Managed Solution :(This is locked and does not allow you to change.
Used only at the time of final deployment)
• Unmanaged Solution :(You can think of a pointer, when a change happens
to one of the entity in one of the solution, the other
solution using the same entity will also get affected)

Characteristics of a solution:
1. Publisher: Each solution is associated with a publisher
2. Version Number : very important in installing and uninstalling process
3. Unique Prefix : just like New in CRM 4.0
4. Solutions are unmanaged by default

Differences between Managed and Un Managed Solutions:
Unmanaged Solution
1. Container that holds references to the components.
2. Multiple solutions can reference same components.
3. Solutions are unmanaged by Default.
4. When Solution deleted only the solution ref from the database gets deleted and will not affect the changes done in any of the customizations/Plugins/web Resources.
5. Cannot be uninstalled.

Managed Solution
1. Designed for final distribution
2. Must be exported as managed
3. Cannot be modified and cannot be exported
4. When Solution Deleted, Entities/Components/web Resources and related data gets deleted permanently.
5. Can be uninstalled
6. Changes performed by the solutions are undone

Possible Scenarios of Import and Export process:
Scenario 1: New Deployment: Version 1.0.0.0
1. Export as a managed solution
2. Publish before you export your managed solution
3. Also, possible to export the system settings like Auto numbers, ISV…
4. Create a backup of Customization
5. From the Target Organization Import the Managed Solution.
a. This takes care of registering the plugins by choosing an option while
import.
b. This takes care publishing too, meaning once imported it automatically be
published.
6. Import would not succeed for managed solution from where it has been created.

Scenario 2: Update/Upgrade to a new version of deployment: Version 1.0.0.1 (SAME Solution name and same Publisher)
1. Once done with the changes to any of the components in the solution,
2. Follow the same steps explained in the Version 1.0.0.0, and keep in mind to change the Version Number to Version 1.0.0.1
3. Once you Import your managed solution from the Target organization the process is quite intelligent in identifying your Solution upgrade version by the solution name.

Scenario 3: Patch version of deployment: Version 1.0.0.0 (DIFFERENT Solution
name and same Publisher).
1. Create a solution with a different name
2. Add the components on which the changes are required
3. Associate the Same Publisher
4. Follow a different versioning format like Version 1.0.0.0
5. Follow the same steps explained in Version 1.0.0.0.

Uninstalling Option:
1. Deleting the managed Solution from the target organization would basically uninstall the selected solution.
2. Let’s say if we have followed a few iterations, for example if we have already reached a Version 1.0.0.5 starting from Version 1.0.0.0. in order to rollback to Version 1.0.0.2 we just need to go follow the same Import process and choose the Version 1.0.0.2 while importing. This would basically bring back the changes to the Version 1.0.0.2.

Wednesday, November 17, 2010

Adding Prerequisites in to Visual Studio 2008

o Bootstrapper Manifest Generator Tool URL: http://code.msdn.microsoft.com/bmg/Release/ProjectReleases.aspx?ReleaseId=1567
(is used for generating the manifest file in the Bootstrapper folder of the VS2008 environment)

The above tool will create a folder and add the manifest files to the following location:

C:\Program Files\Microsoft SDKs\Windows\v6.0A\Bootstrapper\Packages

The folder should have the following files in it:
For example if your adding the SQL Exress 2005 as a prerequisite to the VS 2008,

The tool creates a folder based on the project name provided while creating the
manifest file.

Creating Custom Packages
--------------------------------------------------------------------------------

There are some cases in which you do not have to create a package for your redistributable. Typically, you only have to build packages for shared components or system components, which have to install files to the GAC, perform global registration, or make up a Windows Service.

You should ask the control provider whether you can ship the redistributable file together with the application. If a simple copy operation would be sufficient to redistribute the prerequisite component (for example, if it has no dependencies), you do not have to create a package. Just make sure that the file is included in the setup or that it is set to Copy Local. (The file's Copy property in Properties View should be set to True.)

You should also determine whether you have to use an installer. If so, use a Bootstrapper package.

To create a new component package, you have to supply:

The redistributable component in the form of an EXE or MSI file.

The product manifest, product.xml, which contains any language-neutral metadata for the package. This contains metadata common to all the localized versions of the redistributable component.

The package manifest, package.xml, which contains language-specific metadata; it typically contains localized error messages. A component must have at least one package manifest for each localized version of that component.

How to use the Tool?

Step1:Open the tool and create a project



Step2: Setting up the Manifest project



Step3: Selecting an .exe file


Step4: Final manifest project file


Step5: Build output




Following are the few software download links to configure the Prerequisites in the VS2008

o MDAC Download URL: http://www.microsoft.com/downloads/en/confirmation.aspx?FamilyId=9AD000F2-CAE7-493D-B0F3-AE36C570ADE8&displaylang=en
o SQL Express From FTP: ftp://192.168.1.6/technical/Installables/Microsoft/SQL/SQL 2005 Express SP3

o Crystal Report download URL: http://resources.businessobjects.com/support/additional_downloads/runtime.asp#09 (Follow the attached word document to convert the file to .msi format)

o WSE 3.0 Runtime Download URL: http://www.microsoft.com/downloads/en/details.aspx?FamilyID=9e59c3fb-e7bc-4d91-908e-411a8d329f3d&displaylang=en

Some helpful links:

• http://stackoverflow.com/questions/1334436/adding-custom-prerequsites-to-visual-studio-setup-project
• http://msdn.microsoft.com/en-us/library/ms165429.aspx
• http://msdn.microsoft.com/en-us/library/ms165429(v=VS.90).aspx

Thursday, October 7, 2010

One Click Deployment With Visual Studio 2008 and Windows Server

  • Following are the steps that I have followed to publish the one touch deployment on 2008 windows server.
    In VS 2008 right click on the project that we are trying to publish and select properties
    o Select the Application tab from the left navigation in the properties window
    o By default the Manifest option in the Resources group has been defaulted to “Embed manifest with default settings”. Change this option to “Create application without a manifest”
    o From the Signing tab click on “Create Test Certificate” button to sign the assembly with a strong name
    o From the Publish tab provide the Publishing Folder Location information (http:////),where the files need to be deployed.
    o From the “Install Mode and Settings” choose the appropriate online/offline availability option. Also, include the prerequisites if any for the application by clicking on the prerequisites button
    o Provide the publish version and check the automatically increment revision option if you would like to keep the previous version in the deployed location. Basically it maintains the folder by the publish version numbers
    o Click on “Publish” button to start the publish process.

BEFORE WE DO THE ABOVE STEPS:

1)We need to make sure the Windows 2008 server is installed with Front Page Server Extensions. Keep in mind, we need to install the FPSC and Extend the website with FPSC

2)We can't deploy a Click Once application using http to a machine running Windows Server unless the server has the Front Page Extensions installed.

3)Add the following MIME Types for Click Once deployment
o Here are the basic MIME types you need for every Click Once deployment:
 .application –> application/x-ms-application
 .manifest –> application/x-ms-manifest
 .deploy –> application/octet-stream
o If you are targeting .NET 3.5 or .NET 4.0, you need these as well:
 .msp –> application/octet-stream
 .msu –> application/octet-stream
 Click one of these links to see how to set MIME types in IIS 6 or
IIS 7.
 After successful FPSE installation on Windows Server. Follow the
below mentioned steps.
o Extending Web Sites with FPSE
o Using HTML Administration Pages to Extend a Web Site
a. Click Start, point to Programs, point to Administrative Tools, and then
click Microsoft SharePoint Administrator to open the Server
Administration page.
b. In the list of virtual servers, click Extend next to the virtual server
you want to extend.
c. In the Administrator box, type the user name for the administrator of
the virtual server.
d. Click Submit.

4)To overcome this issue “Web Server Does Not Appear to Have Any Authentication
Methods Enabled”
o Right-Click the server name from IIS and click Properties.
o Click the Directory Security tab on the server's properties dialog box.
o Under the Anonymous Access and Authentication Control section, click Edit.
o Choose either Basic Authentication (password sent in Clear Text) or Windows
NT Challenge/Response and click OK twice.
o Stop and restart the Web server.