Thursday, 27 December 2012

FactBoxes in AX 2012

FactBoxes
A FactBox is a small selection of data related to the current record in the list page.

Three types of Factbox exist:


• Info part: This has its own data source and a number of controls. It is limited in what can be displayed. However it is simple and quick to create, and can also be displayed in the Enterprise Portal.


• Form part: This is a link to a form. The form can have the same controls as a standard form. However since this is displayed in the FactBox section of the list page, adding too many controls can crowd the part.


• Cues: This is a count of a number of records related to the current record in the list page. For example, it might show the number of outstanding invoices for a customer.

Wednesday, 26 December 2012

Creating User or Importing the User in Microsoft Dynamics Ax 2012

Creating User or Importing the User in Microsoft Dynamics Ax 2012




Go to System Administration –>Users–> Users ,   click on Import the User,,

click next select the Domain and give the role by clicking next and click finish.

( You Can Create New User by clicking New User)

Select the User and click on Edit Button–>  a new Window appears

.                                                           user

 

In User’s Roles Tab :click on  Assign User Button a window appears  shown below:

select the Role and click  OK.. If  already roles Present select the role and  click delete button.

 

user2

SSRS Report Configuration

1. System Admin–> setup–>Business Intelligence–>Reporting Service–>Reporting Server

The Following Images Shows :

 

ssrsconfg

1.1) Configuration Id = MSSQLSERVER

1.2) ReportServer

servername = MTSD-01 ( system name)

server instance name = MSSQLSERVER.

1.3)  Reporting Server URL:

1.1) Report Manager URL :http://systemname/Reports

1.2) Web service URL  : http://systemname/ReportServer

1.4) Click on Validate Setting

1.5)  if it is success

 

2.  start–>adminstratot tools–>power shell

type this:

Publish-  AXReport –Id  <SSRSCONFIG-ID>  -ReportName    *, Prescription, SOReport..

 

Thursday, 20 December 2012

Difference Between Morphx and Intellimorph in Dynamics AX 2012

There are two important concepts of Dynamics AX:MorphX IDE and Intellisense.



If you want to make changes to the application you will need MorphX IDE for building, modifying tables. By simply drag and drop you can create Forms and menus. It saves your extra coding effort.  You will only need a bit of coding for advanced business logic; X++ is the programming language that is supported by MorphX IDE.



IntelliMorph is the technology that saves the design time of the developer. A  Developer only has to focus on structure not the layout. In figure bellow you can see how this feature works. Right click the workers grid and click personalize. Here you can see the user has the option to personalize the layout at run time. Developer don’t have to specify the location of the fields or the layout of the form.



intelliMorph is the Runtime Environment embedded in Microsoft Dynamics AX, that draws menus, forms, and reports for Windows- and Web-clients with the correct contents, size, and layout.
For example: 

 

1. When you use field groups, IntelliMorph can automatically update the layout of all related forms and reports whenever a modification is made to the field groups. If you create new forms or reports based on the field groups defined in the standard tables, you will not have to manually update the custom object when the standard tables are modified by an upgrade. 



2. When you create reports, it is recommended that you use the Auto design. When you use the Auto Design the IntelliMorph technology automatically adjusts the layout in your reports.


For more information on IntelliMorph, you can refer to SHANKAR DAS SHARMA Blog and the address of the blog is


http://shankard.com/microsoft-dynamics-training/morhpx-intellimorph-dynamics-ax/

Some Basics of AX

Q.     What is the use of configuration key in Ax?

Ans.   Configuration keys allow administrators to enable or disable features in the application for all users.

Disabling features helps to minimize the attack surface against potential attacks.

Q.      Where one can setup the configuration key?

Ans.   Configuration keys are applied by setting the Configuration Key property on these objects in the Application

Object Tree ( AOT ).

Q.    Can we apply a configuration key on table field and report’s control?

Ans.   Yes.

Q.    Can we create a new configuration key?

Ans.  Yes.

Q.    What is the use of security key in Ax?

Ans.  Security keys allow administrators to set security on a user group level.

Minimizing access on a user group level helps to reduce the attack surface against potential attacks.

Q.    What are all the main reasons to apply user-level security?

Ans.   Allow users to do only their designated tasks.

Protect sensitive data in the database.

Prevent users from inadvertently breaking an application by changing code or objects

on which the application depends.

Q.   What is use of AOS Authorization table property?

Ans. The AOS Authorization table property enables you to specify which data access

operations must undergo user permission checking.

Q.     What are fundamental data access operations for AOS authorization table property?

Ans.  The four fundamental data access operations are create, read, update, and delete.

These operations are represented in combinations by the following AOSAuthorization enumeration values:

         None

         CreateDelete

         UpdateDelete

         CreateUpdateDelete

         CreateReadUpdateDelete

No permission checking is done when the AOSAuthorization property is set to none.

Suppose AOSAuthorization is set to CreateDelete on a given table.

In this case, create and delete operations would be allowed to execute

only if the Application Object Server (AOS) can confirm that the user has the appropriate permissions.

Q.       What is default value of AOSAuthorization table property when a new table will be created?

Ans.   When a new table is created, its AOSAuthorization value is set to none.

 Q.    Will AOSAuthorization property be used for views?

Ans.  Yes.

Q.     What is code access security?

Ans.

1.  Code Access Security (CAS) helps protect APIs that have potential security risks when the APIs are running on

the server.

2.    CAS-enabled APIs called on the server require the use of a permission class—one of the classes derived from

CodeAccessPermission.

Q.  How data authorization in Microsoft Dynamics Ax is performed?

Ans.  Data authorization in Microsoft Dynamics AX is performed in three ways:

1. Implicit authorization .

2. Checks done by setting security properties on Application Object Tree (AOT) objects.

3.   Checks done in X++.

Q.  When there are common methods across tables, which will be the best option to create?

Ans.  Create a map and add those methods and corresponding tables.

Q.  What are the different link types available?

Ans. Active, Delayed, Passive, innerJoin, outerjoin, ExistsJoin, NotExistsJoin.

Q.   Delete Actions.

Ans.   Cascade, restricted, Cascade + restricted.

Q. Which element maintains database consistency when a record is deleted.

Ans.   Delete Action.

Q.  What will happen if one add a delete action to a table and use delete_from statement?

Ans. Database performance will be slow.

Q. Relations.

Ans. Types of relations (normal,  field fixed,  related field fixed).

Q. What is an EDT.

Ans. Extended data types (EDTs) are user-defined types.

EDTs are based on the primitive data types Boolean  integer, real, string, and date, and the composite type

container.

Extended data types are defined in the Application Object Tree (AOT) under the Data Dictionary > Extended Data

Types node.

Q. What is an index?

Ans.  An index is a table-specific database structure that speeds the retrieval of rows from the table.

Indexes are used to improve the performance of data retrieval and sometimes to ensure the existence of unique

records.

Q. What is system index?

Ans.  Microsoft Dynamics AX requires a unique index on each table so if there are no indexes on a table or all the

indexes are disabled, a system index is automatically created.

The system index is created on the RecId and DataAreaId fields if the DataAreaId field exists.

otherwise the system index is created on the RecId field. You can see system indexes in the database but they

aren't visible in the AOT.

Q. How one can create a unique index?

Ans. By setting up the “allow duplicate property” to No.

Q. Can we disable an index?

Ans.  Yes.

Today, I have posted this much of data and will post the remaining data in my leisure time.

Tuesday, 18 December 2012

Some useful code for AX Customization

You can get some useful information for this following blog....

http://archive.msdn.microsoft.com/axcodesamples

Monday, 17 December 2012

Simple UI Builder Class

This UI Builder class is simple class with less code and less effort. UI Builder Class is needed when you want to customize your dialog which pop ups when you open a Report. UI Builder Class helps you to add run time lookups and other controls on the dialog form.



Step1 : Your Class must extends SrsReportDataContractUIBuilder


class SimpleDemoUIBuilder extends SrsReportDataContractUIBuilder
{
DialogField dialogEmplId;
DialogField dialogName;
boolean enable;
SimpleDemoContract contract;

}// two fields emplId and Name will reflect in the lookup in dialog form at the time of report opening.


Step2 : Override the build method


public void build()
{
contract = this.dataContractObject();
dialogEmplId = this.addDialogField(methodStr(SimpleDemoContract, parmEmplId),contract);

}// this method used for adding the field  which is from contract class.


Step3 : Write this below code to get lookup


private void emplIdLookup(FormStringControl emplIdlookup)
{
Query query = new Query();
QueryBuildDataSource qbds_EmplTable;
SysTableLookup sysTableLookup;

// Create an instance of SysTableLookup with the current calling form control.
sysTableLookup = SysTableLookup::newParameters(tableNum(FilterDemo), emplIdlookup);
// Add fields to be shown in the lookup form.
sysTableLookup.addLookupfield(fieldNum(FilterDemo,EmplId));
sysTableLookup.addLookupfield(fieldNum(FilterDemo,Name));
qbds_EmplTable = query.addDataSource(tableNum(FilterDemo));
sysTableLookup.parmQuery(query);
// Perform the lookup
sysTableLookup.performFormLookup();
}


Step4 : Override this method



public void getFromDialog()
{
contract = this.dataContractObject();
super();
}


Step5 : Override this method


public void initializeFields()
{
contract = this.dataContractObject();
}


Step6 : Override this method


public void postBuild()
{
super();
dialogEmplId = this.bindInfo().getDialogField(this.dataContractObject(),methodStr(SimpleDemoContract,parmEmplId));dialogEmplId.registerOverrideMethod(methodStr(FormStringControl, lookup),
methodStr(SimpleDemoUIBuilder,emplIdLookup), this);dialogEmplId.lookupButton(2);
}


the Contract Class code and DP class have already been added to the blog. please check it for further reference but one important part has to be added to the contract class i.e in class declaration, the following part has to be updated.



[DataContractAttribute,SysOperationContractProcessingAttribute(classstr(SimpleDemoUIBuilder))]