Archives

Archives / 2015 / December
  • PLUGIN DEBUGGING CONCEPT

    HOW TO DEBUG A PLUGIN IN MICROSOFT DYNAMICS CRM 2015 ONLINE

    STEP 1:

    Open your SDK folder(plugin tool of CRM SDK 2015 type).

    ->tools->plugin registration tool->plugin registration application

    It opens like this

    clip_image002

    ->double click on that application icon.it opens a window to input your credentials by creating a new connection.

    Enter the details of your CRM credentials and step to login.

    clip_image004

    ->Then perform the profile installation process using Install profiler button.

    It shows like this

    clip_image006

    clip_image008

    Then you will get the message as profile installed successfully in a dialogue box. click on ok button.

    STEP 2:

    Register new assembly in the register column by loading the plugin you have created in .DLL format.

    clip_image010

    clip_image012

    Click on register selected plugins button.

    ->Add the step to the specified plugin you have created.it means on which operation the event have to be fired.

    clip_image014

    clip_image016

    -> Click on register new step button.

    ->click on start profiling button on your selected step.

    clip_image018

    After profiling is done, then debug your profile using debug button. While doing it, it asks some profile details that we have to enter.

    1)profile

    2)assembly location

    3)plugin

    clip_image020

    >>the profile file must be loaded here.

    Step to how to load a profile file:

    Go to CRM and perform the operations where the plugin have to be fired.

    Requirement: Here my requirement is to perform the update operation on a custom entity named employee with some fields. when I want to update eid field then the plugin have to be fired and automatically the insertion of data to be done that I have given in my code.

    clip_image022

    clip_image024

    Now it will generates a log file. Download and save it.

    ->specify this file path in profile column.

    It will externally generates an error.so we have to download the log file while we performing the operations on our CRM. and save that file in a particular area and load this file in the profile area.

    >>assembly location is nothing but where the .dll file is saved.

    >>the plugin is created automatically by plugin class

    Step:3

    Open visual studio of your plugin code.

    ->debug->attach to process.It will opens a pop-up menu. In that

    Select the plugin registration tool for that application.

    clip_image026

    clip_image028

    Click on attach button.

     

    Step:4

    Go to again plugin registration tool and click on start execution process in the debug column. It will starts the execution of your plugin code.

    clip_image030

    Finally the.dll file is made for debugging.If any errors arises then

    Remove them by using debugging concept.

    clip_image031

  • How to Create Trial Microsoft Dynamics CRM Online

    Dynamics CRM is software which is developed by Microsoft, for the purpose of Customer relationship management, like SalesMarketing, and Service.

    CRM is a not a free software, have to purchase it from Microsoft. Thus, Microsoft provided a free trial version.

    Steps to Create Trial CRM are as Follows

    · Search for free Microsoft Dynamics CRM Online Trail in Google search Engine or any search engine and click on the link provided as following.

    · Or https://portal.office.com/Signup/Signup.aspx?OfferId=E070C229-C45D-433d-874A-6B5B3C54B291&dl=CRMSTANDARD&ali=1&culture=en-sg&Country=IN#0 
    clip_image002

    · Or https://portal.office.com/Signup/Signup.aspx?OfferId=E070C229-C45D-433d-874A-6B5B3C54B291&dl=CRMSTANDARD&ali=1&culture=en-sg&Country=IN#0

    clip_image004

    After filling all required details click on Next

    clip_image006

    The following page will opens, fill the all required fields like User name, Company name (it should be Unique), and Password.clip_image008

    Then, Click on next opens the following page, to confirmation.

    clip_image010

    Click on Text me to get a One Time Password, for security reasons

    clip_image012

    On entering code and Click on Create my account leads to following page

    clip_image014

    Save the “your office 365 user ID” and click on “You’re ready to go…à”

    Choose the currency and click on “Finish

    clip_image016

    Save the URL

    clip_image018

    Open the URL in browser leads to the following page, Enter the user ID and Password and click on Sign inCRM will opens with a popup window close the popup to use the CRM

    clip_image020

    clip_image022

    clip_image024

  • Field Level Security In Dynamics CRM

    Introduced In:

    • Field Level Security(FLS) was introduced in MS Dynamics CRM 2011, but works on Custom fields only. Later on, it’s working fine with OOB fields too.

    What Is FLS:

    • Providing security to important data by giving access permission to the users of CRM
    • Restrecting some fields to access some users is FLS, i.e, if an Entity is needed to an Employee as well as a Manager in a company, but Employee has to access only required data.
    • Thus, FLS is implemented to give restriction to users, like Read,Update,Create.
    •  FLS is applied to, the fields which are having Field security as enabled.
    • There are three types of field securities, EnabledDisabled, and Not Applicable.
    • The fields which are having field security as Not Applicable, are not valid for FLS.
    •  Restrictions for boolean fields , only Create and Update can be done but not Read, cause boolean attribute to be either YES/ NO or TRUE/ FALSE.
    • And for Option Set fields, Create, Update, and Read securities can be given when their default value is unspecified.
    • System Administrator can access all data, and can provide securities for different users

    Behaviour when retrieve and Retrieve Multiple

    • When trying to retrieve a secured field, it doesn't throw error but shows the value as null

    Behaviour for Create or Update

    · When programmer create or Update secured data using codding, it throws an error like, Doesn't have sufficient permissions.

     

     

    Steps to Implement Field Level Security:

    · Choose the field to which the Field Security has to be applied , then check whether the field security is enabled or not, if not enabled click on the field and change field security to enabled as follows.

    · Go to Settings –>Customize the system

    clip_image002

    Choose the entity in which FLS has to apply, and click on fields as shown in fig.

    clip_image004

     

     

     

     

     

     

     

     

     

     

     

    How to Enable Field Level Security :

     

    • Double click on field it will open the filed properties window as follows , in that change the Field Security to enabled.

    clip_image006

     

    • Be sure that field security has to be enabled

    ,clip_image008

    •  clip_image009Save and clip_image011publish, if any changes done.
    • After Enabled the Field Security the field showed on the form as follows.

    clip_image013

    How to Configure the Field Security:

    • Go to Settings –>Security –>Field Security Profiles

    clip_image015

    clip_image017

    • Click on clip_image018

    clip_image020New

    • Click on clip_image018[1]New opens following window, and give a name to the profile, and clip_image022save it.clip_image024
    • After the save action Click on Field Permissions

    clip_image026

    • Select the field to which FLS has to apply,

    clip_image028

    • Change the permissions for the actions and click on ok

    clip_image030

    • Click on clip_image031Users to add restricted users for this filter, Click on clip_image031[1]Add

    clip_image033

    • Select user and click on add

    clip_image035

    • Click on clip_image036save and Close
    • Open CRM with the user, to whom the field security profile is added.
    • Open the entity, which contains the FLS applied field.
    • Thus, the user can not be read, update and create as per given permissions.
    • The field will be shown as password field like dotted data
      clip_image038
  • DEPENDENCY OPTIONSET

    This is the concept based on dependency. It means one option set is dependent on another option set.

    For EX:I have a requirement to display all the related values of first option set in second option set only when I select a particular label in first option set.

    CONTENTS REQUIRED:

    1) Jscript library

    2) Form Event

    3) XML Webresouce

    Then we have to do the following steps

    STEP 1:

    Open your CRM. Create two option set fields in an entity and add the options in both fields.

    Ex: My requirement is I have two option set fields named vehicle types and vehicles. When I choose an option in an vehicle type as parent option set, then I have to get the dependent fields of that particular option only in dependent option set.

    clip_image002

    Fig: entity creation

    clip_image004

    Fig: creating parent option set field

    clip_image006

    Fig: creating dependent option set field

    clip_image008

    Fig: vehicles field creation and publish ion

    clip_image009

    Add those fields to the vehicle entity form.

     
     clip_image010

    clip_image011Then save

    Publish

    clip_image013

    Fig: inserting fields to form and get published

    Step 2:

    Create a web resource named vehiclexml which is of xml type in our CRM solution.

    Open the Visual studio and select an xml file in it and the develop the xml code for that following option sets.

    clip_image015

    Fig: vehiclexml.xml file

    clip_image017

    Fig: Creating web resource xml file

    clip_image019

    clip_image021

     

    STEP 3:

    Creating another web resource of java script file named DependentOptionSetSample.js

    following code in that and save it.

    clip_image023

    · above Java Script file find in below link

    https://msdn.microsoft.com/en-us/library/gg594433(v=crm.7).aspx

    clip_image025

    clip_image027

    Fig: Creating web resource of Jscript

    clip_image028STEP 4:

    Goto main form in vehicle entity

    clip_image029

    Form properties.

    In that add the library file of Jscript that was generated in web resources.

    clip_image031

    Fig: Adding Jscript file to the library

    clip_image032clip_image034

    clip_image036

    clip_image038

    Now goto the field of parent option type and then double click on it.

    It opens the event handler where we have to add the functionality of dependency.

    clip_image040

    clip_image042

    clip_image044

    Then go to your CRM and the test the fields on the entity that you have created.

    The following output screen shots are provided here

    Output Screen shots:

    1) The field vehicles is locked because it is dependent on parent option set field named vehicletype.

    clip_image046

     

    2) Select any option in parent option field.

    clip_image048

    3)The related options will appear in the dependent option field

    clip_image050

  • System Work Flow

    In Microsoft Dynamics CRM, rollup fields are designed to help users obtain insights into data by monitoring key business metrics. A rollup field contains an aggregate value computed over the records related to a specified record, such as open opportunities of an account. Also, you’ll be able to aggregate data from the activities directly related to a record, such as emails and appointments, and activities indirectly related to a record via the Activity Party entity. In more complex scenarios, you can aggregate data over the hierarchy of records. As an administrator or customizer, you can define rollup fields by using the customization tools in the CRM Web application, without needing a developer to write code.

    Rollup fields benefits and capabilities

    The benefits and capabilities of rollup fields include the following:

    · Visual editing is easy. You can create rollup fields by using the Field Editor, just like you do when you create a regular field.

    · Wide selection of aggregate functions. You can aggregate data by using the following functions: SUMCOUNTMINMAXand AVG.

    · Full filter support for aggregation. You can set various filters for the source entity or related entity while setting multiple conditions.

    · Seamless integration with the user interface. You can include the rollup fields in forms, views, charts and reports.

    · Rollup fields are solution components. You can easily transport the rollup fields as components between organizations and distribute them in solutions.

    · Rollup fields and the calculated fields are complementary to each other. You can use a rollup field as a part of the calculated field, and vice versa.

    ONE ROLLUP CREATION EXAMPLE

    I am creating roll up field in company entity to find the count of employees in each company, goto company entity> fields>new field>field type>rollup>next click side edit button>gave name in rollup field (no of emp) >source entity keep it don’t change>related entity >gave required related lookup name(employee(companyref))>aggregation>count>employee>save and close.

    clip_image002[1]

    Set the field in form>save >published. when I created one record in company. . It runs once, after you created or updated a rollup field. The job recalculates the specified rollup field value in all existing records that contain this field. By default, the job will run 12 hours after you created or updated a field. After the job completes, it is automatically scheduled to run in the distant future