Posts

Dynamically adding row to table and selected entity related attributes to table dynamically using html in mscrm

<html lang="en" xmlns="http://www.w3.org/1999/xhtml"> <head></head> <body>          <meta charset="utf-8">     <title>Sample page</title>     <script src="../../ClientGlobalContext.js.aspx" type="text/javascript"></script>     <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>     <script src="http://managed.apy.com:5555/apyuthorities/WebResources/mtcsv_/Scripts/Jquery.1.8.2.min.js"></script>     <script src="http://managed.apy.com:5555/apyuthorities/WebResources/apy_Sdknew.js" type="text/javascript"></script>     <!--<script src="Scripts/SDK.MetaData.js" type="text/javascript"></script>-->     <script src="http://managed.apy.com:5555/apy/WebResources/apy_XrmSvcToolkit.js" type="text/javascript"...

Retrieve entity related attribute by SDK.Metadata.RetrieveEntity using javascript in mscrm

   function addColumn(entityName) {                      if (entityName != null && entityName != undefined && entityName != "") {                 SDK.Metadata.RetrieveEntity(SDK.Metadata.EntityFilters.Attributes, entityName, null, false, function (entityMetadata) { successRetrieveEntityData(entityName, entityMetadata); }, errorRetrieveEntity);             }         }         function successRetrieveEntityData(logicalName, entityMetadata) {             attributecount = null;             attributes = [];             attributecount = entityMetadata.Attributes.length;             entityMetadata.Attributes.sort(function (a, b) {             ...

create a record with plugin including with all fields in mscrm

using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using Microsoft.Xrm.Sdk; namespace CreateBookingMovementFromEnquiry {     public class CreateBookingMovement : IPlugin     {         public void Execute(IServiceProvider serviceProvider)         {             ITracingService trace = (ITracingService)serviceProvider.GetService(typeof(ITracingService));             IPluginExecutionContext context = (IPluginExecutionContext)serviceProvider.GetService(typeof(IPluginExecutionContext));             IOrganizationServiceFactory serviceFactory = (IOrganizationServiceFactory)serviceProvider.GetService(typeof(IOrganizationServiceFactory));             IOrganizationService service = serviceFactory.CreateOrganizationService(new Guid?(context....

Using FetchXml Retrieve more than 5000 records with XrmSvcToolkit in MS CRM

var pagingNo; var pageCookie = ""; var FetchXmlBuilder = function () {     return {         getPageCookie: function (a) {             return a;//.replace(/</gi, "&lt;").replace(/>/gi, "&gt;").replace(/\"/gi, "&quot;")         }     } }(); var Bind_Results = new Array(); function xrmSvcTooltRequest() {     var fetch = "<fetch version='1.0' output-format='xml-platform' mapping='logical' distinct='false' page='" + pagingNo + "' count='5000'  paging-cookie='" + pageCookie + "'>" +                 "<entity name='apy_jobpackagetasks'>" +                  "<attribute name='apy_jobpackagetasksid' />" +                  "<attribute name='apy_name' />" +                ...

html page with table inside another table

<!DOCTYPE html> <html lang="en" xmlns="http://www.w3.org/1999/xhtml"> <head>     <meta charset="utf-8" />     <title>Designing html page</title>     <style>         body {             font-family: Segoe\000020UI,Arial,sans\00002Dserif;             font-size: 12px;             color: #444;             padding: 0px;             margin: 0px;         }         table {             border-collapse: collapse;             width: 100%;         }         th {             border-bottom: none!important;             border-right: 1px solid #dd...

Association of records using plugin in MS CRM

using Microsoft.Xrm.Sdk; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using Microsoft.Xrm.Sdk.Query; using Microsoft.Xrm.Sdk.Messages; namespace Marketing_List {     public class Account_Association:IPlugin     {         public void Execute(IServiceProvider serviceProvider)         {             IPluginExecutionContext context = (IPluginExecutionContext)serviceProvider.GetService(typeof(IPluginExecutionContext));             IOrganizationServiceFactory factory = (IOrganizationServiceFactory)serviceProvider.GetService(typeof(IOrganizationServiceFactory));             IOrganizationService service = factory.CreateOrganizationService(context.UserId);             if(context.InputParameters["Target"]is Entity && contex...

Association and Dissociation of records using plugin in MS CRM

using System; using System.Collections; using System.Text; using Microsoft.Xrm.Sdk; using System.Web; using System.Xml; using System.Diagnostics; using Microsoft.Xrm.Sdk.Query; using Microsoft.Xrm.Sdk.Client; using Microsoft.Xrm.Sdk.Messages; namespace Termination { ///// In Enquiry entity we are having the subgrid of CarrirerSupplierRateRequest and RateRequestAdditional /////1. Registering the Plugin on Create and Update CarrirerSupplierRateRequest entity /////2. CarrirerSupplierRateRequest is having the lookup are aki_enquirynumber and aki_raterequestadditionals /////3. Enquiry and RateRequestAdditional entities are having the N:N relationship /////4. creating and updating the CarrirerSupplierRateRequest entity with aki_raterequestadditionals lookup field we are updating the sub grid(raterequestadditionals) in Enquiry entity     public class AssociateAndDissociateRRA : IPlugin     {         public void Execute(IServiceProvid...