{"id":26102,"date":"2021-12-27T07:37:18","date_gmt":"2021-12-27T07:37:18","guid":{"rendered":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/?p=26102"},"modified":"2021-12-27T07:37:20","modified_gmt":"2021-12-27T07:37:20","slug":"easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page","status":"publish","type":"post","link":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/","title":{"rendered":"Easiest way to filter Custom list By Context Id in Entity\u2019s List Page"},"content":{"rendered":"\n<p><a href=\"https:\/\/www.greytrix.com\/product\/crm-development\/sage-crm\" target=\"_blank\" rel=\"noreferrer noopener\">Sage CRM<\/a> has its own .NET API (Application Programming Interface) that allows a developer to extend Sage CRM functionality by creating and using .NET DLLs (Dynamic Link Libraries). Developers can add references of DLLs from and within Sage CRM and thus call methods exposed by the DLLs to perform certain actions. The Sage CRM .NET API is an alternate way of using traditional classic ASP-based customizations in Sage CRM. The .NET API provides a type of library that exposes Sage CRM objects, properties, and methods. Through the core libraries exposed by the .NET API, you can manage data access and Web Interface generation.<\/p>\n\n\n\n<p>Sage CRM provides an SDK of Entity template to create a set of classes to support a custom entity. This entity template allows a developer to create a .NET DLL that provides a customized graphical user interface for Sage CRM custom entities. Creating a new .NET DLL from the entity template doesn&#8217;t create a new entity table, screens, and List blocks in Sage CRM. The developer must need to do this first in the Sage CRM front end or through the Advanced Customization Wizard. When the developer uses the entity template to create a new C# project in Microsoft Visual Studio, the CRM .NET Entity Wizard help to generate the custom pages.<\/p>\n\n\n\n<p>Entity wizard helps you to create Sage CRM Pages that can be used to create, edit, delete, view details of a particular entity instance. After creating an entity template it creates the EntityDataPage, Edit, Delete, New, List and Search pages. These pages help developers to get a basic idea of designing and organizing standard functionalities in .Net API. Also, these pages help to define the screen that allows a user to create, view, and modify entity records in Sage CRM.<\/p>\n\n\n\n<p><strong><em>Related Post :<\/em><\/strong> <a rel=\"noreferrer noopener\" href=\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2019\/09\/30\/adding-a-pipeline-graphic-to-list-using-net-api-in-sage-crm\/\" data-type=\"URL\" data-id=\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2019\/09\/30\/adding-a-pipeline-graphic-to-list-using-net-api-in-sage-crm\/\" target=\"_blank\">Adding a Pipeline graphic to List using .Net API in Sage CRM<\/a><\/p>\n\n\n\n<p>In this blog, we will explain how we can filter list screen with current context Id. Sage CRM SDK provides various options to get context id in .NET DLL.<\/p>\n\n\n\n<p>As per the steps, when the user uses the entity template to create a new C# project in Microsoft Visual Studio, the CRM .NET Entity Wizard starts. In this wizard, it is required to fill complete information of the following options and then click on \u201c<strong>GO<\/strong>\u201d button.<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><strong>New Entity Name:<\/strong> In this option, the user needs to enter the name of the custom entity.<\/li><li><strong>Id field:<\/strong> In this option, the user needs to enter the ID field name of the custom entity table, which was mentioned at the time of creating a new custom entity in Sage CRM.<\/li><li><strong>Prefix:<\/strong> Enter the prefix to be used for the fields in the new custom entity table, which was mentioned at the time of creating the new custom entity table in Sage CRM.<\/li><\/ul>\n\n\n\n<p>On finishing the above steps, the entity template creates various .cs files. We need to open \u201c<strong>EntityListPage.cs<\/strong>\u201d file. This page creates an instance of a specialized web class ListPage. On this page, we need to add FilterByField and FilterByContextId to allow the list to be filtered dynamically within the current context ID.<\/p>\n\n\n\n<p>Below is the sample code snippet used in the Entity List Page &#8211; <\/p>\n\n\n\n<p><em>&lt;Snippet><br>public PeopleList()<br>: base(&#8220;Person&#8221;, &#8220;PersonList&#8221;, &#8220;PersonFilterBox&#8221;)<br>{<br>FilterByField = &#8220;pers_companyid&#8221;;<br>FilterByContextId = (int)Sage.KeyList.CompanyId;<br>}<br>&lt;\/Snippet><\/em><\/p>\n\n\n\n<p>After adding the above code you need to build dll and add it to your Sage CRM \u201c<strong>CustomDotNet<\/strong>\u201d folder.<\/p>\n\n\n\n<p>Now, login into the CRM, it will navigate to the custom list screen of the application and you can see that list will be filtered based on the current context.<\/p>\n\n\n\n<p>In this way, by writing a few lines of C# code in the \u201c<strong>EntityListPage.cs<\/strong>\u201d file, you can modify the filter option based on the current context.<\/p>\n\n\n\n<p><span style=\"font-size: Medium;\"><strong>About Us<\/strong><\/span><\/p>\n\n\n\n<p>Greytrix \u2013 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.<\/p>\n\n\n\n<p>Greytrix\u00a0has some unique integration solutions developed for Sage CRM with Sage ERPs namely\u00a0Sage X3,\u00a0Sage Intacct,\u00a0Sage 100,\u00a0Sage 500,\u00a0and\u00a0Sage 300. We also offer best-in-class\u00a0Sage ERP\u00a0and\u00a0Sage CRM\u00a0customization and development services\u00a0to\u00a0Business\u00a0Partners,\u00a0End\u00a0Users, and Sage PSG worldwide. Greytrix\u00a0helps in\u00a0the migration of Sage CRM from\u00a0Salesforce | ACT! | SalesLogix | Goldmine | Sugar CRM | Maximizer. Our Sage CRM Product Suite includes\u00a0add-ons like\u00a0 Greytrix Business Manager,\u00a0Sage CRM Project Manager,\u00a0Sage CRM Resource Planner,\u00a0Sage CRM Contract Manager,\u00a0Sage CRM Event Manager,\u00a0Sage CRM Budget Planner,\u00a0Gmail Integration,\u00a0Sage CRM Mobile Service Signature,\u00a0Sage CRM CTI Framework.<gwmw style=\"display:none;\"><gwmw style=\"display:none;\"><gwmw style=\"display:none;\"><gwmw style=\"display:none;\"><\/gwmw><\/gwmw><gwmw style=\"display:none;\"><\/gwmw><\/gwmw><\/gwmw><\/p>\n\n\n\n<p>Greytrix is a recognized\u00a0Sage Champion Partner\u00a0for GUMU&#x2122; Sage X3 \u2013 Sage CRM integration listed on\u00a0Sage Marketplace and Sage CRM \u2013 Sage Intacct integration listed on Sage Intacct Marketplace. The GUMU&#x2122; 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.<gwmw style=\"display:none;\"><gwmw style=\"display:none;\"><gwmw style=\"display:none;\"><gwmw style=\"display:none;\"><\/gwmw><\/gwmw><gwmw style=\"display:none;\"><\/gwmw><\/gwmw><\/gwmw><\/p>\n\n\n\n<p>For more information on our integration solutions, please contact us at&nbsp;<a href=\"mailto:sage@greytrix.com\">sage@greytrix.com<\/a>. We will be glad to assist you.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Sage CRM has its own .NET API (Application Programming Interface) that allows a developer to extend Sage CRM functionality by creating and using .NET DLLs (Dynamic Link Libraries). Developers can add references of DLLs from and within Sage CRM and thus call methods exposed by the DLLs to perform certain actions. The Sage CRM .NET\u2026 <span class=\"read-more\"><a href=\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/\">Read More &raquo;<\/a><\/span><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2,3,11,19,29,65,68,73,77,78,92,95,98,119,136,137,169,219,220,332,335,3986,351,352,426],"tags":[446,4522,4519,868,4520,1076,4524,4521,4523,2109],"class_list":["post-26102","post","type-post","status-publish","format-standard","hentry","category-net-api","category-net-framework","category-action-sage-crm","category-administrator","category-asp","category-codeless","category-column","category-configuration","category-context","category-control","category-custom-entity","category-custom-page-sage-crm","category-customization","category-display","category-enhancements","category-entity","category-grids","category-list","category-lists","category-sage-crm","category-sage-crm-2018-crm72","category-sage-crm-2019-r1-sage-crm-2018-crm72","category-screen-sage-crm","category-script","category-visibility","tag-net-api","tag-net-dlls","tag-context-id","tag-custom-list","tag-easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page","tag-entity","tag-entitylistpage-cs","tag-filter-custom-list-by-context-id-in-entitys-list-page","tag-sage-crm-net-api","tag-sage-crm-sdk"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Easiest way to filter Custom list By Context Id in Entity\u2019s List Page - Sage CRM \u2013 Tips, Tricks and Components<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Easiest way to filter Custom list By Context Id in Entity\u2019s List Page - Sage CRM \u2013 Tips, Tricks and Components\" \/>\n<meta property=\"og:description\" content=\"Sage CRM has its own .NET API (Application Programming Interface) that allows a developer to extend Sage CRM functionality by creating and using .NET DLLs (Dynamic Link Libraries). Developers can add references of DLLs from and within Sage CRM and thus call methods exposed by the DLLs to perform certain actions. The Sage CRM .NET\u2026 Read More &raquo;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/\" \/>\n<meta property=\"og:site_name\" content=\"Sage CRM \u2013 Tips, Tricks and Components\" \/>\n<meta property=\"article:published_time\" content=\"2021-12-27T07:37:18+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-12-27T07:37:20+00:00\" \/>\n<meta name=\"author\" content=\"Greytrix\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Greytrix\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/\",\"url\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/\",\"name\":\"Easiest way to filter Custom list By Context Id in Entity\u2019s List Page - Sage CRM \u2013 Tips, Tricks and Components\",\"isPartOf\":{\"@id\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/#website\"},\"datePublished\":\"2021-12-27T07:37:18+00:00\",\"dateModified\":\"2021-12-27T07:37:20+00:00\",\"author\":{\"@id\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/#\/schema\/person\/402abe5da07cd7f9bfeb6acfa41fae39\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Easiest way to filter Custom list By Context Id in Entity\u2019s List Page\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/#website\",\"url\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/\",\"name\":\"Sage CRM \u2013 Tips, Tricks and Components\",\"description\":\"Explore the possibilities with Sage CRM insights through our comprehensive blogs. As a leading Sage partner, Greytrix helps businesses maximize their Sage CRM potential with its rich expertise and immense knowledge. Here, you will find blogs that feature expert advice, tips &amp; tricks, best practices, and comprehensive guides on customizing and configuring Sage CRM for your business. Stay informed with our regular updates and expert insights!\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/#\/schema\/person\/402abe5da07cd7f9bfeb6acfa41fae39\",\"name\":\"Greytrix\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/3cdb553d6ca07df0e407d5e092f2410d163e0fd40b27734b345b04c8f0786969?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/3cdb553d6ca07df0e407d5e092f2410d163e0fd40b27734b345b04c8f0786969?s=96&d=mm&r=g\",\"caption\":\"Greytrix\"},\"url\":\"https:\/\/www.greytrix.com\/blogs\/sagecrm\/author\/greytrix\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Easiest way to filter Custom list By Context Id in Entity\u2019s List Page - Sage CRM \u2013 Tips, Tricks and Components","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/","og_locale":"en_US","og_type":"article","og_title":"Easiest way to filter Custom list By Context Id in Entity\u2019s List Page - Sage CRM \u2013 Tips, Tricks and Components","og_description":"Sage CRM has its own .NET API (Application Programming Interface) that allows a developer to extend Sage CRM functionality by creating and using .NET DLLs (Dynamic Link Libraries). Developers can add references of DLLs from and within Sage CRM and thus call methods exposed by the DLLs to perform certain actions. The Sage CRM .NET\u2026 Read More &raquo;","og_url":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/","og_site_name":"Sage CRM \u2013 Tips, Tricks and Components","article_published_time":"2021-12-27T07:37:18+00:00","article_modified_time":"2021-12-27T07:37:20+00:00","author":"Greytrix","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Greytrix","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/","url":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/","name":"Easiest way to filter Custom list By Context Id in Entity\u2019s List Page - Sage CRM \u2013 Tips, Tricks and Components","isPartOf":{"@id":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/#website"},"datePublished":"2021-12-27T07:37:18+00:00","dateModified":"2021-12-27T07:37:20+00:00","author":{"@id":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/#\/schema\/person\/402abe5da07cd7f9bfeb6acfa41fae39"},"breadcrumb":{"@id":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/2021\/12\/27\/easiest-way-to-filter-custom-list-by-context-id-in-entitys-list-page\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/"},{"@type":"ListItem","position":2,"name":"Easiest way to filter Custom list By Context Id in Entity\u2019s List Page"}]},{"@type":"WebSite","@id":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/#website","url":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/","name":"Sage CRM \u2013 Tips, Tricks and Components","description":"Explore the possibilities with Sage CRM insights through our comprehensive blogs. As a leading Sage partner, Greytrix helps businesses maximize their Sage CRM potential with its rich expertise and immense knowledge. Here, you will find blogs that feature expert advice, tips &amp; tricks, best practices, and comprehensive guides on customizing and configuring Sage CRM for your business. Stay informed with our regular updates and expert insights!","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/#\/schema\/person\/402abe5da07cd7f9bfeb6acfa41fae39","name":"Greytrix","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/3cdb553d6ca07df0e407d5e092f2410d163e0fd40b27734b345b04c8f0786969?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/3cdb553d6ca07df0e407d5e092f2410d163e0fd40b27734b345b04c8f0786969?s=96&d=mm&r=g","caption":"Greytrix"},"url":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/author\/greytrix\/"}]}},"_links":{"self":[{"href":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/wp-json\/wp\/v2\/posts\/26102","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/wp-json\/wp\/v2\/comments?post=26102"}],"version-history":[{"count":2,"href":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/wp-json\/wp\/v2\/posts\/26102\/revisions"}],"predecessor-version":[{"id":26104,"href":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/wp-json\/wp\/v2\/posts\/26102\/revisions\/26104"}],"wp:attachment":[{"href":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/wp-json\/wp\/v2\/media?parent=26102"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/wp-json\/wp\/v2\/categories?post=26102"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.greytrix.com\/blogs\/sagecrm\/wp-json\/wp\/v2\/tags?post=26102"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}