Component Recording

Hints, Tips and Tricks

Technical Hints Tips and Tricks that cover customization and development using Sage CRM. API usage and coding are covered.

Component Recording

  • Comments 12
  • Likes

When working with the Component Manager it is possible to record customizations that you make and input to another CRM system.

This is an extemely handy feature saving lots of time , effort and possible tantrums. Recording a component is very straighforward. I will walk you through the few short steps required, below:

 Some initial things to point out are that you will need to have an EIS license and the Main Entity Wizard installed in order to avail of this feature.

So, on with the recording:

Log into CRM as Admin and navigate to Administration -> Customization -> Component Manager

Click onto the Component Details tab

You should see two existing entries

 

One for the Advanced Customization Wizard (MEW) and another called Changed this changed component is set up by default and tracks all changes made to the system.

To start recording a new component , first script out the Changed component so that you have a snapshot of the CRM system as it is.

To script out the component , simply click on the Sript Component on the right hand side of the screen and copy the script to CRM's inf directory.

Once you have done this go to your Program Files\Sage\CRM\inf folder and copy the Changed directory together with the changed.ecf to a zip file give it name e.g. changedbkp.zip. Now you have essenitally saved all changes made to your system to date.

Next return to the Administration -> Customization -> Component Manager-> Component Details tab and select New

Fill in the name and description details, if you are ready to begin recording straight away then tick the ' set to be current' checkbox

 

 

 

Carry out whatever changes you wish to make within CRM, in my example below I have added additional fields to the Project entity under field Customization

Once you have completed all of the actions which you wish to record, return to the  Administration -> Customization -> Component Manager-> Component Details tab and choose

Script Component

This will write the recorded files to your Program Files\Sage\CRM\inf folder.

 

  

 

 

To import and use this component in another CRM instance , simply colect the files from your Program Files\Sage\CRM\inf folder add them to a zip file and import the zip file using Component Manager

When you are more familiar with Component Recording the are more Advanced Options available to you such as linking other existing components to the current component.

 

Finally be sure to return to the Administration -> Customization -> Component Manager-> Component Details tab and uncheck the 'set to be current' value for this component.

If you wish to continue recording you can revert to the 'Changed' component as the current component. To stop recording altogether select the Stop Component Manager action on the right hand side.

Happy recording !

 

 

 

 

 

Comments
  • When I create a new multi-select field through the UI it creates an NVarChar(255) field in the database but component manager tries to create it as NChar(255). Using the fixed width data type means that it instantly gobbles 510 bytes and can easily push a table row over the 8000 byte limit.

    The upshot is that I can happily create changes through the UI that cannot be scripted because the script causes a SQL error. Is there some way to get the component manager script to use the variable width NVarChar data type?

  • DarntonB

    Interesting....

    When you create a new column of entry type 'Multi-Select' on a table the component manager code is...

    AddColumn('Company','comp_test','10','(255)','true','false');

    var EditsId11729 = AddCustom_Edits('Company','comp_test','28','0','','1','comp_test','','','','');

    AddCustom_Data('Custom_Edits', 'ColP', 'ColP_ColPropsId','ColP_ColPropsId, ColP_DataType, ColP_DataSize', EditsId11729+',"4","255"','1');

    AddCustom_Data('Custom_Edits','ColP','ColP_ColPropsId','ColP_ColPropsId,ColP_TiedFields',EditsId11729+',","','1');

    AddCustom_Data('Custom_Edits','ColP','ColP_ColPropsId','ColP_ColPropsId,ColP_SSViewField',EditsId11729+',","','1');

    The method used is AddColumn (www.sagecrm.com/.../Default_CSH.htm) and the Entry Type to be created in the database is the controlled by the third parameter.

    I have mentioned the Entry Types here:  community.sagecrm.com/.../sage-crm-entrytypes-used-in-the-com-asp-api.aspx

    So... I think you will have to change the value of the third parameter from 10 to 28.

  • Thanks Jeff. That little bit of on-the-fly editing of the .es script works.

    I trust this item is now on the developers' to do list :-)

  • I have this logged as a case.

  • Hi I'm very new to Sage but have 20+ yrs experience as a software engineer.  My colleagues here tell me the BEST way to migrate customizations from dev to test to prod is to meticulously write down every change I make, then I can re-create them in each environment as we promote manually.  They say, component recording dosn't work, it leaves out too many things and they spend less time (and create fewer errors) simply re-entering everything than they would tracking down all the issues with using the component manager.  Honestly I am shocked to hear this.  I'm either shocked that Sage can't support this most basic software engineering process, or I am shocked that my co-workers have their heads buried... somewhere! LOL  So what's the deal??  Please help this new guy out

    -David

  • Hi David - Jeff is travelling at the moment, and will probably reply to your comment later. Component recording is an important part of Sage CRM and there have been many improvements to it over the years. Its is very flexible, in that you can view and edit the component scripts before running them in the target system. Search for component manage on this site and you'll find plenty of tips and pointers. If you have a specific question about whether some particular customisation will be recorded, then post it up in the forum and someone will help.

  • thanks!  I guess I should soften my comments a bit - when pressed my friends here did admit 'for what you are doing, David, it works just fine'. So I am going to use this method it seems to be working just fine for me so far.

  • Hi David,

    Welcome to the Sage Community. Although component manager works in 90% of areas, some complex customisations may require some manual intervention.  If there are areas that are not working you shuold log any issues with your regional support team so that we can fix them

    I think to get the most out of component manager you really have to understand how the sage CRM metadata works I recommend taking a look at our articles and discussions on here relating to both component manager and metadata

    I hope this helps

    Elaine

  • Hi, We are working on a CRM project which involves 20 custom entities and multiple programmers are working on different entities and workflow. Is there any way we can copy the entities and the customizations from the development system to the production server. Few times, we have to port the customization of a specific entity only. We can move the asp files manually but, is there any way to copy the customization through a database script or any other ways. Any help on this is highly appreciated.

  • Prakash

    Do have a look at the number of articles that the team have written about the Component Manager.  community.sagecrm.com/.../SearchResults.aspx  This is the tool that allows you to carry over files customization from a development server into a live environment.

    Think of it as a install shield programming environment - any component that you create will need to be thoroughly tested and NOT taken for granted.

  • Just did this- very helpful. One step was missing in the blog, which is to remember to click "stop component manager" when you are done making your configurations.

  • Please can someone offer me some advise.

    HOW do you record the removal of CRM default choices?

    EG I record component changes I make to the Company element, in particular the "Comp_Employees" where I remove all default entries and create new ones.

    Upon a fresh install of CRM, these default values obviously get re-created. When I install the component I recorded it doesn't actually record the removal of these choices, so I have to manually go back in and remove them all again.

    Please advise is there a way I can edit the *.es script to add in code to remove these default entries added during CRM install?

    Thanks