Client Side Script to Concatenate Address

By | December 13, 2019

Sage CRM, is one of the most flexible software to customize and achieve any complex requirement specified by the client. Client-side scripts are brought into play for many purposes. On change, functions can be used to hide/show fields on the screen. Likewise, you can also highlight fields by including conditions to your script or show alerts message to users.

New Stuff: Incorporate Case filter screen in Self Service portal

In this blog, we will describe how useful client-side functions be by gathering data from multiple areas and concatenate them in one single field. Here, we will gather Address information from various fields and display them into a single multi-text field under address entity. You can refer the below steps do so.

  1. Log in to Sage CRM.
  2. Navigate to below path. Administration |Customization| Entity | Screens.
  3. Refer below screenshot to add the script.
  4. Save the screen.
Custom Content
Custom Content
<script>
$(document).ready(function() {
function ConcateFields() {
crm.fields('addr_fulladdress').val(crm.fields('addr_address1').val()+"\n"+
crm.fields('addr_address2').val()+"\n"+crm.fields('addr_address3').val()+
"\n"+crm.fields('addr_address4').val()+"\n"+crm.fields('addr_city').val()+
"\n"+crm.fields('addr_state').val()+"\n"+crm.fields('addr_postcode').val()+
"\n"+crm.fields('addr_country').val());
}}
ConcateFields();
$("input,select").change(ConcateFields);
});

Once you have applied the above script, you will be able to see the concatenated address details into the multi-text field as shown below.

Full Address
Full Address

About Us

Greytrix – a globally recognized and one of the oldest Sage Development Partners is a one-stop solution provider for Sage ERP and Sage CRM organizational needs. Being acknowledged and rewarded for multi-man years of experience and expertise, we bring complete end-to-end assistance for your technical consultations, product customizations, data migration, system integrations, third-party add-on development, and implementation competence.

Greytrix has some unique integration solutions developed for Sage CRM with Sage ERPs namely Sage X3Sage IntacctSage 100Sage 500, and Sage 300. We also offer best-in-class Sage ERP and Sage CRM customization and development services to Business Partners, End Users, and Sage PSG worldwide. Greytrix helps in the migration of Sage CRM from Salesforce | ACT! | SalesLogix | Goldmine | Sugar CRM | Maximizer. Our Sage CRM Product Suite includes addons like  Greytrix Business ManagerSage CRM Project ManagerSage CRM Resource PlannerSage CRM Contract ManagerSage CRM Event ManagerSage CRM Budget PlannerGmail IntegrationSage CRM Mobile Service SignatureSage CRM CTI Framework.

Greytrix is a recognized Sage Champion Partner for GUMU™ Sage X3 – Sage CRM integration listed on Sage Marketplace and Sage CRM – Sage Intacct integration listed on Sage Intacct Marketplace. The GUMU™ Cloud framework by Greytrix forms the backbone of cloud integrations that are managed in real-time for the processing and execution of application programs at the click of a button.

For more information on our integration solutions, please contact us at sage@greytrix.com. We will be glad to assist you.