Posts

Showing posts from April, 2019

Adding Symbol Font Icons to a Grid in Dynamics 365

Image
Adding a symbol icon on a grid can be a useful way to provide information to end users and to make the information a bit more visually appealing.   To do this, first select a symbol you want from the relevant symbol font, which can be found at the link below. This is also useful to keep track of new and changing symbols in every new version . Add some fields and create a new “Image” control on the grid. We will now create a display method that can be used from the LogisticsPostalAddress DataSource. We don’t want to overlay the table, we want to extend it. To do this, create a final class with a name that ends in “_Extension”. Decorate it with the “ExtensionOf” attribute so that the compiler can handle it.  We are going to create a display method that returns a container. Here’s the sample code: [ ExtensionOf ( tableStr ( PurchLine ))] public static class  SMJSalesLine_Extension { [ SysClientCacheDataMethodAttribute ( true )]   public static display

What exactly does executeQuery() do?

                   On a form level you have datasource, one or more. You build a query specifying relations between them. Executequery executes this query to get data from underlying tables and show it on a form. executeQuery method is executed when a form is opened for data display. The executeQuery method can be overridden on a form data source by right-clicking the Methods node under the data source, pointing to Override Method, and then clicking executeQuery. Examples:            The following example executes a data source query. public void executeQuery() {   this .query().dataSourceNo( 1 ).clearRanges();    if (CityCode.valueStr() != "" )   {       QueryBuildRange qbrCityCode;      qbrCityCode = this .query().dataSourceNo( 1 ).addRange( fieldNum (SMJ_CandidateDetails,CityCode));      qbrCityCode.value(CityCode.valueStr());    }     super ();  }

SSRS Report using Controller , Contract and RDP classes in D365

Image
STEP 1 : Create new TEMP table STEP 2 : Create query. STEP 3 : Create a Contract class [DataContractAttribute] class SMJ_PerdiemContract {     PerdiemStatus    perdiemstatus;     [DataMemberAttribute(identifierStr(PerdiemStatus)),         SysOperationLabelAttribute ("Perdiem status"),         SysOperationHelpTextAttribute("Perdiem status"),         SysOperationDisplayOrderAttribute("1")]         public PerdiemStatus parmPerdiemStatus(PerdiemStatus _PerdiemStatus = perdiemstatus)     {         perdiemstatus = _PerdiemStatus;         return perdiemstatus;     } } STEP 4 : Create a DP class: [SRSReportQueryAttribute(queryStr(SMJ_PerdiemReport)), // query  SRSReportParameterAttribute(classStr(SMJ_PerdiemContract))]// contract class     public class SMJ_PerdiemDP extends SRSReportDataProviderBase {     SMJ_PerdiemTableTempDB  perdiemTableTempDB;     PerdiemStatus           perdiemStatus;        PerdiemRequestID        PerdiemRequ

Number Sequence in D365

Step 1: Create EDT Step 2: Use that EDT in the Table where it is required Step 3: Select the Class module which you going to implement this Number seq. class NumberSeqModuleVehicleDetails extends NumberSeqApplicationModule {     Protected void loadModule()     {         NumberSeqDatatype datatype = NumberSeqDatatype ::construct();          /* Setup application numbers */         datatype.parmDatatypeId( extendedtypenum ( VehiclId )); //your EDT         datatype.parmReferenceLabel(literalstr("Mobile id")); //your Label         datatype.parmReferenceHelp(literalstr("Mobile id"));         datatype.parmWizardIsContinuous( true );         datatype.parmWizardIsManual( NoYes ::No);         datatype.parmWizardIsChangeDownAllowed( NoYes ::No);         datatype.parmWizardIsChangeUpAllowed( NoYes ::No);         datatype.parmWizardHighest( 2000 );          datatype.parmWizardfetchAheadQty( 10 );         datatype.parmSortField(