Tag Archives: Disable
Disable field in Business Process Flow in D365 CE using JavaScript
Use case – Our requirement is to mark field Purchase time Frame disabled in Business process flow on change of disable field(custom field) on opportunity form. Let’s see how we can achieve this Solution – Step 1 – Create web resource with below function- Add header_process before schema name of field. Here schema name of purchase time frame field is purchasetimeframe. And after adding header_process_purchasetimeframe var opportunityCustomization = { //opportunityCustomization.disableField disableField : function(executionContext) { var formContext = executionContext.getFormContext(); var disable = formContext.getAttribute(“cf_disable”).getValue(); if (disable == true) { formContext.getControl(“header_process_purchasetimeframe”).setDisabled(true); } } } Step 2: Add this web resource on form load, on Save and on change of the field. And try Output – Hope this helps !
Enable/Disable & Visibility an Action pane button on a list page using interaction class in D365
Introduction: In this blog, we will see how we can enable/disable or change the visibility of the form control in interaction class. Standard behavior of the form, system does not allow us to write code on form which comes under form template -> List page It Seems like below attached image (Here we will consider form VendTableListPage. Property of form as shown below) Each ListPage form consisting with an interaction class as shown in property, Here it is VendTableListInteraction. Each interaction class has one override method which is selectionchanged() Solution: Here we will override the method of selectionchanged() as below [ExtensionOf(classStr(VendTableListPageInteraction))] final class VendTableListPageInteractionCFSJSClass_Extension public void selectionChanged() { next selectionChanged(); //for visibility this.listPage().actionPaneControlVisible(formControlStr(VendTableListPage, ), false); //for enable/disable this.listPage().actionPaneControlEnabled(formControlStr(VendTableListPage, true); } For all other ListPage, we can go through interaction class. For reference, go through below mentioned classes: AgreementListPageInteraction BankDocumentTableListPageInteraction CatProcureOrderListPageInteraction CatVendorCatalogListPageInteraction CustBillOfExchEndorseListPageInteraction CustomsExportOrderListPageInteraction CustPDCListPageInteraction CustPDCSettleListPageInteraction CzCustAdvanceInvoiceListPageInteraction CzVendAdvanceInvoiceListPageInteraction EcoResCategoryHierarchyPageInteraction EcoResProductListPageInteraction EmplAdvTableListPageInteraction EntAssetObjectCalendarListPageInteraction EntAssetWorkOrderPurchaseListPageInteraction EntAssetWorkOrderPurchReqListPageInteraction EntAssetWorkOrderScheduleListPageInteraction EPRetailPickingListPageInteraction EPRetailStockCountListPageInteraction EximAuthorizationListPageInteraction EximDEPBListPageInteraction EximEPCGListPageInteraction GlobalAddBookListPageInteraction HcmCourseAttendeeListPageInteraction HcmWorkerAdvHoldTableListPageInteraction InventBatchJournalListPageInteraction InventDimListPageInteractionAdapter JmgProdStatusListPageInteraction JmgProjStatusListPageInteraction PCProductModelListPageInteraction PMFSeqReqRouteChangesListPageInteraction ProdBOMVendorListPageInteraction ProdRouteJobListPageInteraction ProdTableListPageInteraction ProjForecastListPageInteraction ProjInvoiceListPageInteraction ProjInvoiceProposalListPageInteraction ProjProjectContractsListPageInteraction ProjProjectsListPageInteraction projProjectTransListPageInteraction ProjUnpostedTransListPageInteraction PurchCORListPageInteraction PurchCORRejectsListPageInteraction PurchLineBackOrderListPageInteraction PurchReqTableListPageInteraction PurchRFQCaseTableListPageInteraction PurchRFQReplyTableListPageInteraction PurchRFQVendorListPageInteraction_PSN PurchRFQvendTableListPageInteraction PurchTableVersionListPageInteraction ReqTransActionListPageInteraction ReqTransFuturesListPageInteraction ReqTransListPageInteraction RetailOnlineChannelListPageInteraction RetailSPOnlineStoreListPageInteraction ReturnTableListPageInteraction SalesAgreementListPageInteraction SalesQuotationListPageInteraction SalesTableListPageInteraction SysListPageInteractionBase SysUserRequestListPageInteraction UserRequestExternalListPageInteraction UserRequestListPageInteraction VendEditInvoiceHeaderStagingListPageInteraction VendNotificationListPageInteraction VendPackingSlipJourListPageInteraction VendPDCListPageInteraction VendPDCSettleListPageInteraction VendProfileContactListPageInteraction VendPurchOrderJournalListPageInteraction VendRequestCategoryListPageInteraction VendRequestListPageInteraction VendRequestWorkerListPageInteraction VendTableListPageInteraction VendUnrealizedRevListPageInteraction Thanks for reading !!!
How To Enable / Disable Maintenance mode Using SQL query in Dynamics 365 for Finance & Operations
In finance and operations for making any changes in License configuration form, you need to enable maintenance mode and after making desirable changes you need to disable to this mode. You can enable or disable maintenance mode using SQL query as well as command prompt. In this blog, we are performing this operation using the SQL query. The following are steps to enabling/disabling maintenance mode:- Open SSMS(Microsoft SQL Server Management Studio) in your server. Click on New Query and enter the following query to enable maintenance mode:- update dbo.SQLSYSTEMVARIABLESset dbo.SQLSYSTEMVARIABLES.VALUE =1 where dbo.SQLSYSTEMVARIABLES.PARM = ‘CONFIGURATIONMODE’ You can verify status using following command:-SELECT * FROM [AxDB].[dbo].[SQLSYSTEMVARIABLES] After this restart IIS services in some cases, you need to restart the server. perform your changes to the License configuration form. after desired changes are made you can disable mode using the following command update dbo.SQLSYSTEMVARIABLESset dbo.SQLSYSTEMVARIABLES.VALUE =0 where dbo.SQLSYSTEMVARIABLES.PARM = ‘CONFIGURATIONMODE’ Now again you can verify status using the same query in step 3 and again repeat step 4.I hope this blog will help you