Microsoft MB6-890: Questions & Answers

Réussis tes devoirs et examens dès maintenant avec Quizwiz!

Question 69: You write the following X + +code: (Line numbers are included for reference only.) 01 CustTable custTable; 02 try 03 { 04 custTable.AccountNum = "123"; 05 custTable.CustGroup = "20"; 06 custTable.Currency = "USD"; 07 custTable.insert(); 08 } 09 You need to handle the deadlock exception and the error exception. Which code segment should you insert at line 09? A) catch(Exception::deadlock) catch(Exception::error) info("Exception occurred"); B) catch(Exception) info("Exception occurred"); } C) catch(Exception::deadlock) info("Exception occurred"); catch(Exception::error) info("Exception occurred"); D) catch(Exception::deadlock. Exception::error) info("Exception occurred");

<no answer given>

Question 79: You write the following X + +code: (Line numbers are included for reference only.) 01 CustTable custTable; 02 try 03 { 04 custTable.AccountNum = "123"; 05 custTable.CustGroup = "20"; 06 custTable.Currency = "USD"; 07 custTable.insert(); 08 } 09 You need to handle the deadlock exception and the error exception. Which code segment should you insert at line 09? A) catch(Exception::deadlock) catch(Exception::error) info("Exception occurred"); B) catch(Exception) info("Exception B occurred"); } C) catch(Exception::deadlock) info("Exception occurred"); catch(Exception::error) info("Exception occurred"); D) catch(Exception::deadlock. Exception::error) info("Exception occurred");

<no answer given>

Question 89: You write the following X + +code: (Line numbers are included for reference only.) 01 CustTable custTable; 02 try 03 { 04 custTable.AccountNum = "123"; 05 custTable.CustGroup = "20"; 06 custTable.Currency = "USD"; 07 custTable.insert(); 08 } 09 You need to handle the deadlock exception and the error exception. Which code segment should you insert at line 09? A) catch(Exception::deadlock) catch(Exception::error) info("Exception occurred"); B) catch(Exception) info("Exception B occurred"); } C) catch(Exception::deadlock) info("Exception occurred"); catch(Exception::error) info("Exception occurred"); D) catch(Exception::deadlock. Exception::error) info("Exception occurred");

<no answer given>

Question 1: You have a table that contains invoices. You need to create a Fact Box that displays the number of invoices in the table. Which type of Fact Box should you use? A) form part B) cue group C) cue D) info part

Explanation: * Info part: part that shows a collection of data fields from a specified query. An info part uses metadata to describe how the data appears. As a result, you can use an info part in both the client and EP. * FactBox type: Fields and values Info part or form part A FactBox that shows a list of field names and values. The value can include a link that opens the record in a form. Incorrect: Not A: Form Part A part that represents a pointer to a form. You use a form part when you want a form to appear in the FactBox pane, enhanced preview, or preview pane. Not B: cue group A part that includes reference to one or more cues. You use a cue group to list a collection of query results. Typically, the list shows summary data that is related to a record or a task. Reference: Parts [AX 2012]

Question 60: You work in a shared development environment. You frequently use private projects. Which statement accurately describes the private projects? A) Changes made to the objects in the private projects are visible only to the user who creates the projects. B) Private projects can have only one version in source control. C) Other users can be granted access to the private projects by using security roles. D) Private projects are visible only to the user who creates the projects.

Explanation: A project is either private or shared. Private projects are only available to the user who created them. Shared projects are available to all users and can be used as a tool for work groups to manage their work. Reference: MorphX Development Projects [AX 2012]

Question 62: You have three tables named Table1, Table2, and Table3. Table2 and Table3 extend from Table You define a method on Table2 and you define a field on Table1. You need to identify on which tables the field and the method will be available. Which two options should you identify? Each correct answer presents part of the solution. A) The field will be available on Table1 only. B) The field will be available on Table1, Table2, and Table3. C) The method will be available on Table2 and Table3 only. D) The method will be available on Table2 only. E) The method will be available on Table1, Table2, and Table3.

Explanation: A table can extend from or derive from another table. Each table has the SupportInheritance property and the Extends property, which together control table inheritance. Reference: Table Inheritance Overview [AX 2012]

Question 72: You have three tables named Table1, Table2, and Table3. Table2 and Table3 extend from Table You define a method on Table2 and you define a field on Table1. You need to identify on which tables the field and the method will be available. Which two options should you identify? Each correct answer presents part of the solution. A) The field will be available on Table1 only. B) The field will be available on Table1, Table2, and Table3. C) The method will be available on Table2 and Table3 only. D) The method will be available on Table2 only. E) The method will be available on Table1, Table2, and Table3.

Explanation: A table can extend from or derive from another table. Each table has the SupportInheritance property and the Extends property, which together control table inheritance. Reference: Table Inheritance Overview [AX 2012]

Question 82: You have three tables named Table1, Table2, and Table3. Table2 and Table3 extend from Table You define a method on Table2 and you define a field on Table1. You need to identify on which tables the field and the method will be available. Which two options should you identify? Each correct answer presents part of the solution. A) The field will be available on Table1 only. B) The field will be available on Table1, Table2, and Table3. C) The method will be available on Table2 and Table3 only. D) The method will be available on Table2 only. E) The method will be available on Table1, Table2, and Table3.

Explanation: A table can extend from or derive from another table. Each table has the SupportInheritance property and the Extends property, which together control table inheritance. Reference: Table Inheritance Overview [AX 2012]

Question 2: Which three types of components can be customized by using the Morph X development environment? Each correct answer presents a complete solution. A) Dynamics A AX security roles B) Dynamics AX Enterprise Portal pages C) Dynamics AX client forms D) Microsoft SQL Server Reporting Services (SSRS) reports E) Dynamics AX tables

Explanation: A: Microsoft Dynamics AX AOT allows the developer to manage role-based security. Under AOT > Security the developer manages permissions, privileges, duties, roles, and policies. CE: * MorphX is the IDE for Microsoft Dynamics AX, its features include: - Tools for creating menus, forms and reports for Windows- and W eb clients * In Microsoft Dynamics AX, the Application Object Tree (AOT) contains all of the definitions of elements that are used to build Microsoft Dynamics AX, such as classes, tables, forms, and so on. Reference: AOT Overview [AX 2012] Role-based Security in the AOT for Developers [AX 2012]

Question 77: You need to identify which elements a job can contain. Which two elements should you identify? Each correct answer presents part of the solution. A) Embedded methods B) Variable declarations C) Class instantiations D) Events

Explanation: A: You can declare local functions inside a method or a job in X++. A local function can contain code that would otherwise have to be duplicated in two or more places within your method. B: The following X++ job demonstrates that the print statement automatically converts any data type to a string. To create a job in the AOT, right-click the Jobs node, and then click New Job. static void PrintJob2(Args _args) { str s1 = "Hello"; int n2 = 42; utcDateTime udt3 = DateTimeUtil::utcNow(); Dialog dlog4 = new Dialog(); Etc. Reference: Local Functions [AX 2012]; Print Statements [AX 2012]

Question 87: You need to identify which elements a job can contain. Which two elements should you identify? Each correct answer presents part of the solution. A) Embedded methods B) Variable declarations C) Class instantiations D) Events

Explanation: A: You can declare local functions inside a method or a job in X++. A local function can contain code that would otherwise have to be duplicated in two or more places within your method. B: The following X++ job demonstrates that the print statement automatically converts any data type to a string. To create a job in the AOT, right-click the Jobs node, and then click New Job. static void PrintJob2(Args _args) { str s1 = "Hello"; int n2 = 42; utcDateTime udt3 = DateTimeUtil::utcNow(); Dialog dlog4 = new Dialog(); Etc. Reference: Local Functions [AX 2012]; Print Statements [AX 2012]

Question 67: You need to identify which elements a job can contain. Which two elements should you identify? Each correct answer presents part of the solution. A) Embedded methods B) Variable declarations C) Class instantiations D) Events

Explanation: A: You can declare local functions inside a method or a job in X++. A local function can contain code that would otherwise have to be duplicated in two or more places within your method. B: The following X++ job demonstrates that the print statement automatically converts any data type to a string. To create a job in the AOT, right-click the Jobs node, and then click New Job. static void PrintJob2(Args _args) { str s1 = "Hello"; int n2 = 42; utcDateTime udt3 = DateTimeUtil::utcNow(); Dialog dlog4 = new Dialog(); Etc. Reference: Local Functions [AX 2012]; Print Statements [AX 2012]

Question 30: You create a duty to maintain customer master information. You need to identify to which elements you can add the duty. Which two elements should you identify? Each correct answer presents a complete solution. A) Process Cycles B) Policies C) Permissions D) Privileges E) Roles

Explanation: Add or modify the content of the privilege or duty. * (C) To add permissions to a duty or privilege, click Add... to open the Add permissions to privilege form. * (D) To add an existing privilege to a duty, right-click the privilege in the left pane, and then click Copy. Right-click the duty, and then click Paste. Reference: Create or modify a security privilege, duty, or process cycle [AX 2012]

Question 10: You have a Dynamics AX development environment. You need to delete the data in a specific table manually. What should you use? A) The Type hierarchy browser B) The Delete Actions of the table C) The Code profiler D) The Table Browser

Explanation: After you have created a forms interface and entered data in a table, you can use the table browser to view and edit data. Reference: Use the Table Browser to View, Add, Modify, or Delete Records [AX 2012]

Question 61: Which three tasks are performed by an Application Object Server (AOS)? Each correct answer presents a complete solution. A) Manages client sessions B) Stores the Dynamic AX models C) Enforces security for Dynamic AX data and features D) Runs the X++- code E) Hosts help files

Explanation: An Application Object Server (AOS) is a core component of the Microsoft Dynamics AX 2012 installation and is installed by using Setup. An AOS enforces security, manages connections between clients and the database, and provides the foundation where Microsoft Dynamics AX business logic is executed. The following diagram shows the AOS architecture. <there was no image> Reference: Application Object Servers [AX 2012]; AOS architecture [AX 2012]

Question 71: Which three tasks are performed by an Application Object Server (AOS)? Each correct answer presents a complete solution. A) Manages client sessions B) Stores the Dynamic AX models C) Enforces security for Dynamic AX data and features D) Runs the X++ code E) Hosts help files

Explanation: An Application Object Server (AOS) is a core component of the Microsoft Dynamics AX 2012 installation and is installed by using Setup. An AOS enforces security, manages connections between clients and the database, and provides the foundation where Microsoft Dynamics AX business logic is executed. The following diagram shows the AOS architecture. Reference: Application Object Servers [AX 2012]; AOS architecture [AX 2012]

Question 81: Which three tasks are performed by an Application Object Server (AOS)? Each correct answer presents a complete solution. A) Manages client sessions B) Stores the Dynamic AX models C) Enforces security for Dynamic AX data and features D) Runs the X++ code E) Hosts help files

Explanation: An Application Object Server (AOS) is a core component of the Microsoft Dynamics AX 2012 installation and is installed by using Setup. An AOS enforces security, manages connections between clients and the database, and provides the foundation where Microsoft Dynamics AX business logic is executed. The following diagram shows the AOS architecture. Reference: Application Object Servers [AX 2012]; AOS architecture [AX 2012]

Question 7: You need to add a menu item to a list page. To which pane should you add the menu item? A) Preview B) Action C) Filter D) Fact Box

Explanation: An action pane and action pane strip is a collection of buttons that represent the tasks and operations associated with a Microsoft Dynamics AX form. The action pane buttons access menu items that are defined in the AOT. When you add a button to an action pane button group, the application object tree (AOT) enables you to select the following types of buttons: Command button Menu item button Menu button Button Reference: List Page Reference [AX 2012]

Question 41: You create a privilege to maintain vendor information. To which two elements can you add the privilege? Each correct answer presents a complete solution. A) Policies B) Process Cycles C) Duties D) Roles E) Permissions

Explanation: B: To add an existing duty or privilege to a process cycle, right-click the duty or privilege in the left pane, and then click Copy. Right-click the process cycle, and then click Paste. C: To add an existing privilege to a duty, right-click the privilege in the left pane, and then click Copy. Right-click the duty, and then click Paste. Reference: Create or modify a security privilege, duty, or process cycle [AX 2012]

Question 90: You have the following X++ statement: You need to identify the output of the statement. What should you identify? Int variableA, variableB; Int _parameter = 3; Try { while(variableA < _parameter) { if(variableA == 1) { break; } else if(variableA > 2) { throw error("Variable2 cannot have value greater than 2."); } variableA++; } if(variableB < variableA) { error("Wrong value of variableB variable."); } } Catch (Exception::Error) { error("Process was aborted."); } Catch (Exception::Break) { error("Process was cancelled."); } A) Process was cancelled. Wrong value of variableB variable. B) Wrong value of variableB variable. C) Variable2 cannot have value greater than 2. Process was aborted. D) Wrong value of variable B variable. Process was cancelled.

Explanation: By default the integer variables VariableA and VariableB will be set 0. Break; statement will be run as VariableA is 1. The line error("Wrong value of variableB variable."); will be executed as VariableB VariableA. No exception is thrown. Note: A frequently thrown exception is Exception::error enumeration value. This exception is thrown in a variety of situations. It is common practice to write diagnostic information to the Infolog before throwing the exception, and the Global::error method is often the best way to do that. In X++ code, the static methods on the Global class can be called without the Global:: prefix. For example, the Global::error method can be called simply as error ("My message.");. Incorrect; Not A, not D: Exception Break: Indicates that the user has pressed BREAK or CTRL+C. Reference: Exception Handling with try and catch Keywords [AX 2012]

Question 20: You have a class named Class1 that contains a static method named smethod1 and an instance method named method2. Class1 contains the following X+ + code: (Line numbers are included for reference only.) 01 class Class1 02 { 03 int var1; 04 } 05 static void smethod1() 06 { 07 } 08 public void method2() 09 { 10 11 } You need to call smethod1 from method2. Which code segment should you insert at line 10? A) Class1.smethod1() B) Class1::smethod1() C) This::smethod1() D) This.smethod1()

Explanation: Calling a Static Method In the following example, there is no need to first construct an instance of the SoftwareKey class before you call a static method on the class. To call the static method validateSoftwareKey, the syntax starts with the name of the class that contains the method. A pair of colon (::) characters is used to connect the class name to the static method name. boolean yourBool = SoftwareKey::validateSoftwareKey(yourSoftwareKeyString); Reference: Static Methods [AX 2012]

Question 18: You need to replace a value from a specific position of a container. Which function should you use? A) ConDel B) ConPoke C) ConFind D) ConNull

Explanation: ConPoke modifies a container by replacing one or more of the existing elements. Incorrect: Not A: ConDel removes the specified number of elements from a container. Reference: conPoke Function [AX 2012]

Question 32: You need to set the code permission of an action menu item. Which property should you use? A) Linked Permission Object B) Configuration Key C) Needed Access Level D) Web Secure Transaction

Explanation: Create a Menu Item Linked to a Code Permission You can create a menu item by following these steps: 1. Create the menu item TestMenuItem in the CodePermissionsProject project. 2. In the Properties window for the TestMenuItem menu item, set the properties to the values that are shown in the following table. Property|Value Label|Code Permissions Test ObjectType|Class Object|TestClass LinkedPermissionType|CodePermission LinkedPermissionObject|TestCodePermission Reference: Walkthrough: Creating a Code Permission under AOT Security [AX 2012]

Question 55: You are developing a solution to store sales orders in Dynamics AX. Each sales order can contain multiple sales order lines. A sales order line can be part of only one sales order. You create two tables named Sales Table and Sales Line. The tables will model the sales order and the sales order line entities. Sales Table will store sales orders and Sales Line will store sales order lines. You need to specify the relationship between the tables. W hich relationship should you specify? A) foreign key relationship from Sales Table A to Sales Line B) A field fixed relationship from Sales Table to Sales Line C) A foreign key relationship from Sales Line to Sales Table D) A related field fixed relationship from Sales Line to Sales Table

Explanation: Create a foreign key relationship in the Sales Line, which is on in many-side of the relationship, to the Sales table, which is on the one-side of the one-to-many relationship.

Question 53: You have two tables named CustTable and Cust Group. Each record in CustTable references a record in Cust Group. You need to create a delete action to ensure that the records in Cust Group can be deleted only if there are no records in CustTable that reference the record in Cust Group. What should you do? A) On Cust Group, create a Cascade delete action for CustTable. B) On Cust Group, create a Restricted delete action for CustTable. C) On CustTable, create a Restricted delete action for Cust Group. D) On CustTable, create a Cascade delete action for Cust Group.

Explanation: Delete Action: Restricted Restricts deletion in the current table if data is present in related tables. Note: Setting the DeleteAction property to Restricted extends the functionality of the table's validateDelete method. As a result, super(), in validateDelete, checks whether records exist on related tables. If records do exist, validateDelete returns false. The forms system ensures that the deletion is not performed. In your own X++ code, check the return value of validateDelete. Don't delete the primary or related records if the method returns false. Example On the CustTable table, a restricted delete action has been defined for the CustTrans table. When a customer is deleted in the CustTable table, the validateDelete method ascertains whether transactions exist for the customer in the CustTrans table. If so, validateDelete returns false. Reference: How to: Create Delete Actions [AX 2012]

Question 63: You need to create a user interface that displays all of the records for a custom module. The user interface must have an action pane, filters, a grid, form parts, and preview information. Which form template should you use? A) Detail Form Transaction B) List Page C) Simple List D) Drop Dialog

Explanation: DetailsFormTransaction Use the template to create details form with lines to view, edit, and act on master data that has line items. Incorrect: ListPage Use the template to create a list page you can use to find, analyze, and performs actions on master data. SimpleList Use the template to create a simple list form to view, edit, and act on dependent or reference data. DropDialog Use the template to create a drop dialog form to perform an action with data. Reference: Form Overview [AX 2012]

Question 73: You need to create a user interface that displays all of the records for a custom module. The user interface must have an action pane, filters, a grid, form parts, and preview information. Which form template should you use? A) Detail Form Transaction B) List Page C) Simple List D) Drop Dialog

Explanation: DetailsFormTransaction Use the template to create details form with lines to view, edit, and act on master data that has line items. Incorrect: ListPage Use the template to create a list page you can use to find, analyze, and performs actions on master data. SimpleList Use the template to create a simple list form to view, edit, and act on dependent or reference data. DropDialog Use the template to create a drop dialog form to perform an action with data. Reference: Form Overview [AX 2012]

Question 83: You need to create a user interface that displays all of the records for a custom module. The user interface must have an action pane, filters, a grid, form parts, and preview information. Which form template should you use? A) Detail Form Transaction B) List Page C) Simple List D) Drop Dialog

Explanation: DetailsFormTransaction Use the template to create details form with lines to view, edit, and act on master data that has line items. Incorrect: ListPage Use the template to create a list page you can use to find, analyze, and performs actions on master data. SimpleList Use the template to create a simple list form to view, edit, and act on dependent or reference data. DropDialog Use the template to create a drop dialog form to perform an action with data. Reference: Form Overview [AX 2012]

Question 11: You need to store the preferred method of correspondence in a table named DirPersonTable. The solution must meet the following requirements: The table must have a field that stores the preferred method of correspondence. The field must have values of Mail, E-mail, or Unknown. The text representing the preferred method of correspondence values on forms must be localized to the language used by the user. The values in the database must not be localized. How should you create the field in DirPersonTable? A) Create an extended data type (EDT) used to store the preferred method of correspondence. The EDT must extend from the string. Use the EDT to create the field in Dir Person Table. B) Create an enum that stores the preferred method of correspondence and has the values of Mail, E-mail, and Unknown. Use this enum to create the field in DirPersonTable. C) Create a string field that stores the preferred method of correspondence. D) Create an integer field that stores the preferred method of correspondence.

Explanation: EDT can be used for localization. Both EDT and base enums can be used as extension for a field. So why to create an EDT for a base enum? This is because, Only EDTs can be used when adding a field to dialog. If a field used in a dialog is of the type enum like NoYes, even then the extended data type NoYesId ex- tending the base enum NoYes must be used.

Question 21: Which elements can contain X++ methods? A) Info parts B) Tables C) Enumerators D) Extended data types (EDTs)

Explanation: Every table object has instance methods that can be categorized as either system-defined or application-defined. Tables in Microsoft Dynamics AX have a number of system-defined methods, such as insert, validateField, validateWrite. Note: Methods can be created on many kinds of items in the AOT other than just classes. The list includes the following: Maps Views Data Sets Forms Queries Reference: Table Methods [AX 2012]

Question 34: You have a table named sales Table that contains the data shown in the following table. ID|SalesId|Description|CustAccount|RecId 01|SO0001|Order 1|CUST001|1234567 02|SO0002|Order 2|CUST001|1234568 03|SO0003|Order 3|CUST001|1234569 You have the following X++ statement: SalesTable salesTable; select Description, CustAccount from salesTable Where salesTable.recid == 1234569; print strfmt("%1-%2",salesTable.SalesId, salesTable.Description); pause; You need to identify the output of the X++ statement. What should you identify? A) Order3- B) -Order3 C) SO0003- D) SO0003-Order3

Explanation: Strfmt formats the specified string and substitutes any occurrences of % n with the nth argument. Syntax: str strFmt(str _string, ...) Reference: strFmt Function [AX 2012]

Question 78: You need to extract the last three characters from the string value of 122018 by using X++ code. Which two code segments achieve this goal? Each correct answer presents a complete solution. A) = substr('122018', 0,3) B) = substr('122018', 4,3) C) = substr('122018', 6,-3) D) = str2num('122018', 3) E) = str2num('122018', -3)

Explanation: Subst retrieves part of a string. str subStr(str _text, int _position, int _number) Parameters: _text The original string. _position The position in the original string where the part to retrieve begins. _number A signed integer that indicates the direction and number of positions to retrieve from the original string. If there is a minus sign preceding _number, the system selects the substring backward from the specified position. Incorrect: Not d, not E: str2Num converts a string to a real number. Syntax: real str2Num(str _text) Reference: subStr Function [AX 2012]

Question 88: You need to extract the last three characters from the string value of 122018 by using X++ code. Which two code segments achieve this goal? Each correct answer presents a complete solution. A) = substr('122018', 0,3) B) = substr('122018', 4,3) C) = substr('122018', 6,-3) D) = str2num('122018', 3) E) = str2num('122018', -3)

Explanation: Subst retrieves part of a string. str subStr(str _text, int _position, int _number) Parameters: _text The original string. _position The position in the original string where the part to retrieve begins. _number A signed integer that indicates the direction and number of positions to retrieve from the original string. If there is a minus sign preceding _number, the system selects the substring backward from the specified position. Incorrect: Not d, not E: str2Num converts a string to a real number. Syntax: real str2Num(str _text) Reference: subStr Function [AX 2012]

Question 68: You need to extract the last three characters from the string value of 122018 by using X++ code. Which two code segments achieve this goal? Each correct answer presents a complete solution. A) = substr('122018', 0,3) B) = substr('122018', 4,3) C) = substr('122018', 6,-3) D) = str2num('122018', 3) E) = str2num('122018', -3)

Explanation: Subst retrieves part of a string. str subStr(str _text, int _position, int _number) Parameters: _text The original string. _position The position in the original string where the part to retrieve begins. _number A signed integer that indicates the direction and number of positions to retrieve from the original string. If there is a minus sign preceding _number, the system selects the substring backward from the specified position. Incorrect: Not d, not E: str2Num converts a string to a real number. Syntax: real str2Num(str _text) Reference: subStr Function [AX 2012]

Question 37: You need to develop X++ code to fetch data from a database by using a query object. Which class should you use to perform the fetch operation? A) Query Run B) Query Build Range C) Query D) Query Build Data Source

Explanation: The QueryRun class traverses tables in the database, fetches records that satisfy constraints that are given by the user, and helps to gather such constraints from user input. Reference: QueryRun Class [AX 2012]

Question 5: You enable a feature for a Dynamics AX instance. What should you use? A) An extensible data security A (XDS) policy B) A configuration key C) The Table Permissions Framework (TPF) D) A security key

Explanation: The administrator can enable or disable configuration keys to control the features and functionality that are available in Microsoft Dynamics AX. Reference: Configure application functionality [AX 2012] Incorrect: Not A: XDS is a powerful mechanism that allows the ability to express and implement complex data security needs.

Question 38: You are creating an extensible data security (XDS) policy. You need to return the data from the primary table that will be used to filter the data in a constrained table. What should you use? A) The Code profiler B) Code permissions C) Secured APIs D) A policy query

Explanation: You can define a policy query by specifying a value for the Query property in the AOT at Security > Policies > YourPolicy. You can use a policy query to secure the constrained tables speci- fied in a given security policy. The query selects data from a primary table. The values in that data are then used to restrict the data returned from the constrained table. Reference: Overview of Security Policies for Table Records [AX 2012]

Question 49: You have a menu item named menu item l that is used to launch a form named Form l by using the rich client. You need to ensure that users who are granted the Maintain customer addresses privilege can use menu item l to open Forml in read mode. What should you do? A) Set menu item 1 to run on the server. Modify the Enabled property of the Maintain customer addresses privilege. B) Create an entry point for the Maintain customer addresses privilege. Set the Access Level property of the entry point C) Create an entry point for the Maintain customer addresses privilege. Add Form1 to the Maintain customer addresses privilege. D) Set menu item l to run on the server. Add Form l to the Maintain customer addresses privilege.

Explanation: * The developer does the following: Creates a form and a menu item for a form. Creates a privilege and an entry point. Creates a test role for the application user. * (see 4d below) Create a Privilege and an Entry Point You can create a privilege and an entry point for MyMenuItem by following these steps: 1. Create a privilege that is named MyNewPrivilege. 2. Expand AOT > Security > Privileges > MyNewPrivilege. 3. Add an entry point that is named MyNewEntryPoint. You do this by right-clicking the Entry Points node, and then clicking New Entry Point. 4. In the Properties window for the new entry point, do the following: a. Set the Name property to MyNewEntryPoint. b. Make the ObjectType of the entry point be MenuItemDisplay. c. Make the ObjectName of the entry point be MyMenuItem. d. Set the AccessLevel of the entry point to Read. * Example: Create a Test Role To properly test your form as an application user, you must create a test role. You can create a test role by following these steps: 1. Create a test role for an application user that is named TestRole. 2. Expand AOT > Security > Roles > TestRole > Privileges. 3. Add MyNewPrivilege privilege to the Privileges node of TestRole. The following figure shows a test role with a privilege that you create in this walkthrough. <image> Reference: Walkthrough: Using Roles and Privileges to Control Access to Forms [AX 2012]

Question 45: You have a Dynamics AX deployment that contains three legal entities. You need to search for records across all three legal entities. What should you create? A) A select statement that uses the data Area Id field in a where clause B) A select statement that joins the Company Info table C) A select statement that uses the data Area Id field in a field list D) A select statement that uses the cross Company keyword

Explanation: A cross-company query returns data for several companies in a single run. A query does not have to be limited to returning data for the current session company. A cross-company query operates over all companies that you have read permissions for, or over a subset of companies that you specify. Note: A company is a unique identifier for the data that is associated with the legal entity. A company can be associated with only one legal entity, and a legal entity can be associated with only one company. Reference: Cross-Company Data Access [AX 2012]

Question 8: You need to display data on a new form. What should you do? A) Add a data source and create a design. B) Add a data source and set a caption. C) Add a data source and create a method. D) Add a form part and set a caption.

Explanation: A form data source is the database query, table, or view that a form uses to retrieve the data that is displayed by the form. The data source also defines a connection to the Application Object Server (AOS) that the form can use to create, update, or delete database records. A data design element (controls) displays data on a form. Incorrect: Not B: A data source has no caption. Reference: Forms Best Practices [AX 2012]; Forms Best Practices [AX 2012]

Question 54: You have a table named Table1 that contains a string field named Description. Users want to search for records in Table1 based on words that might be present in Description. The words can be anywhere in the Description field. You need to ensure that when the users create queries that are filtered based on the Description field, the query results must be returned in the least amount of time possible. What should you do on Table1? A) Create a non-unique index in Description. B) Add Description to the AutoSummary field group. C) Create a full text index in Description. D) Write a find method.

Explanation: A full text index contains location information about each significant word in a string field of a table. Some queries can use this information to run more efficiently and complete much sooner. These are queries that search for words that are embedded in the middle of string fields A regular index on a long string field can help a query complete quickly only if the query searches for the word that is at the start of the string field. In X++ SQL this is done with the like keyword and the * wildcard character, such as in the code phrase like "*diamond*". Reference: Full Text Index Overview [AX 2012]

Question 6: Which statement accurately describes a model in Dynamic AX? A) A model can be used to group other models. B) A model can group elements at multiple layers. C) A model can group elements only at a specific layer. D) An element that exists only in one layer can be in multiple models in the same layer.

Explanation: A model is a set of elements in a given layer. Each layer consists of one or more models. Each layer contains one system-generated model that is specific to that layer. Every element in a layer belongs to only one model. In other words, no element can belong to two models in the same layer, and every element must belong to a model. Note: Models were introduced in Microsoft Dynamics AX 2012 to help partners and customers more easily install and maintain multiple solutions side by side in the same layer. Reference: Models, Layers, and the Model Store [AX 2012]

Question 19: You have a job that contains the following X++ code: (Line numbers are included for reference only.) 01 int numerator = 10; 02 int denominator = 0; 03 int answer = 0; 04 str string = "this is a string"; 05 try 06 { 07 answer = numerator / denominator; 08 answer = answer + strLen(string); 09 } 10 11 { 12 info("error"); 13 } You need to identify which code must be inserted at line 10 to ensure that line 12 executes. Which code segment should you insert at line 10? A) Catch (exception::error) B) Catch (exception::warning) C) Catch (exception::sequence) D) Catch (exception::numeric)

Explanation: A numeric exception is thrown when a problem occurs during the use of any numerical function as is clearly the case in this code sample. Note: In X++, an exception is represented by a value of the enum named Exception. A frequently thrown exception is Exception::error enumeration value. The catch statements are processed in the same sequence that they appear in the X++ code. It is common to have the first catch statement handle the Exception::Error enumeration value. One strategy is to have the last catch statement leave the exception type unspecified. This means it handles all exceptions that are not handled by a previous catch. This strategy is appropriate for the outermost try - catch blocks. X++ try { /* Code here. */ } catch (Exception::Numeric) { info("Caught a Numeric exception."); } catch { info("Caught an exception."); } Reference: Exception Handling with try and catch Keywords [AX 2012]

Question 75: You have the following X++ code: (Line numbers are included for reference only.) 01 public class Class1 02 { 03 int variable1; 04 int variable2; 05 } 06 public void method1(int _variable1 = variable1) 07 { 08 variable1 = _variable1; 09 } 10 public int method2() 11 { 12 13 return variable2; 14 } 15 public class Class2 16 { 17 } 18 public void method3(Class1 classObj) 19 { 20 int variable3; 21 22 } Method1 and method2 are in Class1. Method3 is in Class2. You need to set variable1 for class1 Obj to a value of 5. Which code segment should you insert at line 21? A) class1 Obj.method1(5); B) new Class1().method1(5); C) class1 Obj.variable1 = 5; D) this.variable1 = 5;

Explanation: All classes are public, but all member variables are implicitly private. Use a public Setter Accessor method, here method1, on Obj1 to change the variable of the other class. Example: Add a Setter Accessor Method Follow these steps to add a method that sets the value of a member variable: 1. Right-click the Class1 node, and then click New > Method. 2. Rename the method1 node to setFirstName. 3. In the code Editor window, paste in the following X++ code for the method. X++ public void setFirstName(str _firstName){ firstName = _firstName;} Reference: Declaration of Classes [AX 2012]

Question 65: You have the following X++ code: (Line numbers are included for reference only.) 01 public class Class1 02 { 03 int variable1; 04 int variable2; 05 } 06 public void method1(int _variable1 = variable1) 07 { 08 variable1 = _variable1; 09 } 10 public int method2() 11 { 12 13 return variable2; 14 } 15 public class Class2 16 { 17 } 18 public void method3(Class1 class1Obj) 19 { 20 int variable3; 21 22 } 01 public class Class1 02 { 03 int variable1; 04 int variable2; 05 } 06 public void method1(int _variable1 = variable1) 07 { 08 variable1 = _variable1; 09 } 10 public int method2() 11 { 12 13 return variable2; 14 } 15 public class Class2 16 { 17 } 18 public void method3(Class class1Obj) 19 { 20 int variable3; 21 22 } Method1 and method2 are in Class1. Method3 is in Class2. You need to set variablel for class1 Obj to a value of 5. Which code segment should you insert at line 21? A) classl Obj.methodl(5); B) new Classl().methodl(5); C) classl Obj.variable1 = 5; D) this.variable1 =5:

Explanation: All classes are public, but all member variables are implicitly private. Use a public Setter Accessor method, here method1, on Obj1 to change the variable of the other class. Example: Add a Setter Accessor Method Follow these steps to add a method that sets the value of a member variable: 1. Right-click the Class1 node, and then click New > Method. 2. Rename the method1 node to setFirstName. 3. In the code Editor window, paste in the following X++ code for the method. X++ public void setFirstName(str _firstName){ firstName = _firstName;} Reference: Declaration of Classes [AX 2012]

Question 85: You have the following X++ code: (Line numbers are included for reference only.) 01 public class Class1 02 { 03 int variable1; 04 int variable2; 05 } 06 public void method1(int _variable1 = variable1) 07 { 08 variable1 = _variable1; 09 } 10 public int method2() 11 { 12 13 return variable2; 14 } 15 public class Class2 16 { 17 } 18 public void method3(Class1 class1Obj) 19 { 20 int variable3; 21 22 } 01 public class Class1 02 { 03 int variable1; 04 int variable2; 05 } 06 public void method1(int _variable1 = variable1) 07 { 08 variable1 = _variable1; 09 } 10 public int method2() 11 { 12 13 return variable2; 14 } 15 public class Class2 16 { 17 } 18 public void method3(Class1 class1Obj) 19 { 20 int variable3; 21 22 } Method1 and method2 are in Class1. Method3 is in Class2. You need to set variable1 for class1 Obj to a value of 5. Which code segment should you insert at line 21? A) class1 Obj.methodl(5); B) new Classl( ).methodl(5); C) class1 Obj.variable1 = 5; D) this.variable1 = 5;

Explanation: All classes are public, but all member variables are implicitly private. Use a public Setter Accessor method, here method1, on Obj1 to change the variable of the other class. Example: Add a Setter Accessor Method Follow these steps to add a method that sets the value of a member variable: 1. Right-click the Class1 node, and then click New > Method. 2. Rename the method1 node to setFirstName. 3. In the code Editor window, paste in the following X++ code for the method. X++ public void setFirstName(str _firstName){ firstName = _firstName;} Reference: Declaration of Classes [AX 2012]

Question 26: You have a class named Class1 that has a public method named method1. For method1, you plan to create an event handler that is defined in the Application Object Tree (AOT). For the event handler, you need to develop code that runs after method1 executes. What should you use to define the code for the event handler? A) A display method on a table B) A static method on a class C) The new method on a class. D) A public instance method on a class

Explanation: All event handlers that subscribe to a method must return void. Event handlers for host methods can use one of two parameter signatures: One parameter of the type XppPrePostArgs The same parameters that are on the host method that the event handler subscribes to The following code shows an example of an event handler that has the XppPrePostArgs class as the only parameter. X++ static public void myEventHandler(XppPrePostArgs _ppArgs) { // Add useful code here.} Note: * In the AOT, you can assign a method as an event handler for the pre-method event or the postmethod event of another method. W e say the event handler subscribes to an event of the host method. The nodes that represent the subscription of an event handler to a host method are underneath the node for the host method. AOT elements such as classes, tables, and forms can have methods. * You can subscribe methods as event handlers in two locations in the Application Object Tree (AOT): Under a delegate node Under a method node Reference: Event Handler Nodes in the AOT [AX 2012]

Question #14 You have the following X++ statement: Int variableA, variableB; In _parameter = 3; Try { while(variableA < _parameter) { if(variableA == 1) { break; } else if(variableA > 2) { throw error("Variable2 cannot have value greater than 2."); } variableA++; } if(variable(b < variableA) { error("Wrong value of variableB variable."); } } Catch (Exception::Error) { error("Process was aborted."); } Catch (Exception::Break) { error("Process was cancelled."); } A) Wrong value of variableB variable. B) Wrong value of variableB variable. Process was cancelled. C) Variable2 cannot have value greater than 2. Process was aborted. D) Process was cancelled. Wrong value of variableB variable.

Explanation: All variables must be declared before they can be used. When a variable is declared, memory is also allocated and the variable is initialized to the default value. Variable b would be initialized to 0 by default. Reference: Declaration of Variables [AX 2012]

Question 70: You have the following X++ statement: Int variableA, variableB; Int _parameter = 3; Try { while(variableA < _parameter) { if(variableA == 1) { break; } else if(variableA > 2) { throw error("Variable2 cannot have value greater than 2."); } variableA++; } if(variableB < variableA) { error("Wrong value of variableB variable."); } } Catch (Exception::Error) { error("Process was aborted."); } Catch (Exception::Break) { error("Process was cancelled."); } You need to identify the output of the statement. What should you identify? A) Process was cancelled. Wrong value of variable B variable. B) Wrong value of variable B variable. C) Variable2 cannot have value greater than 2. Process was aborted. D) Wrong value of variable B variable. Process was cancelled.

Explanation: By default the integer variables VariableA and VariableB will be set 0. Break; statement will be run as VariableA is 1. The line error("Wrong value of variableB variable."); will be executed as VariableB VariableA. No exception is thrown. Note: A frequently thrown exception is Exception::error enumeration value. This exception is thrown in a variety of situations. It is common practice to write diagnostic information to the Infolog before throwing the exception, and the Global::error method is often the best way to do that. In X++ code, the static methods on the Global class can be called without the Global:: prefix. For example, the Global::error method can be called simply as error ("My message.");. Incorrect; Not A, not D: Exception Break: Indicates that the user has pressed BREAK or CTRL+C. Reference: Exception Handling with try and catch Keywords [AX 2012]

Question 80: You have the following X++ statement: Int variableA, variableB; Int _parameter = 3; Try { while(variableA < _parameter) { if(variableA == 1) { break; } else if(variableA > 2) { throw error("Variable2 cannot have value greater than 2."); } variableA++; } if(variableB < variableA) { error("Wrong value of variableB variable."); } } Catch (Exception::Error) { error("Process was aborted."); } Catch (Exception::Break) { error("Process was cancelled."); } You need to identify the output of the statement. What should you identify? A) Process was cancelled. Wrong value of variable B variable. B) Wrong value of variable B variable. C) Variable2 cannot have value greater than 2. Process was aborted. D) Wrong value of variable B variable. Process was cancelled.

Explanation: By default the integer variables VariableA and VariableB will be set 0. Break; statement will be run as VariableA is 1. The line error("Wrong value of variableB variable."); will be executed as VariableB VariableA. No exception is thrown. Note: A frequently thrown exception is Exception::error enumeration value. This exception is thrown in a variety of situations. It is common practice to write diagnostic information to the Infolog before throwing the exception, and the Global::error method is often the best way to do that. In X++ code, the static methods on the Global class can be called without the Global:: prefix. For example, the Global::error method can be called simply as error ("My message.");. Incorrect; Not A, not D: Exception Break: Indicates that the user has pressed BREAK or CTRL+C. Reference: Exception Handling with try and catch Keywords [AX 2012]

Question 33: You need to provide a user from Active Directory with access to Dynamics AX. The user will access Dynamics AX by using the Dynamics AX client. The user will be an internal user. In addition to the users functional role, which two roles should you assign to the user? Each correct answer presents part of the solution. A) Manager B) Guest C) Employee D) Claims user E) System user

Explanation: C: Microsoft Dynamics AX users are internal employees of your organization, or external cus- tomers and vendors, who require access to Microsoft Dynamics AX to perform their jobs. E: The System user security role represents a worker who is enabled to use basic Microsoft Dy- namics AX features such as alerts. Incorrect: Not B: The Guest security role must be assigned to the guest user account to grant access to the tables and web content that are needed for anonymous access to the public Enterprise Portal site. Not D: A claims user is a type of Microsoft Dynamics AX user. Claims users are authenticated by an external system, not by Application Object Server (AOS). To gain authorization to access services, a claims user must be authenticated, and then impersonated by a trusted intermediary user. A trusted intermediary must always be an Active Directory user, never a claims user. A trusted intermediary can impersonate any other Microsoft Dynamics AX user, even a claims user. Reference: Create new users in Microsoft Dynamics AX [AX 2012]; Minimize System user security role (SystemUser) [AX 2012]

Question 31: You need to add a duty to the Accounts receivable manager role. What are two possible menus or nodes that can be used to achieve this goal? Each correct answer presents a complete solution. A) The Setup menu from Organization administration B) The Setup menu from Accounts receivable C) The Security node in the Application Object Tree (AOT) D) The Setup menu from the System administration module

Explanation: C: You can view and edit roles in the Security > Roles node in the AOT. You can right-click the Roles node to add a new role, and drag-and-drop duties from the Security > Duties node to add duties to a role. D: To create or modify a security privilege or duty Click System administration > Setup > Security > Security privileges. Reference: Create or modify a security privilege, duty, or process cycle [AX 2012]

Question 47: You need to identify how the Application Object Server (AOS) implements Code Access Security to prevent secured APIs from being invoked by untrusted code. Which three verifications are performed by the AOS? Each correct answer presents part of the solution. A) That the assert is executed on the multiple tiers from the secured class B) That the code asserts the appropriate permission on the call stack to use the secured class C) That the assert is executed in trusted code and saved in the Application Object Tree (AOT) D) That the assert is executed on the same tier as the secured class E) That the assert modifies the client only invocations of the secured class

Explanation: Call a CAS-enabled API 1. Declare a variable for the relevant permission class. 2. Create a new instance of the class. 3. Request permission by using the assert method on the permission class. 4. Revert the assertion (to limit the scope of the permission) after the CAS-enabled API has been used; optional. Permission is automatically reverted when the method finishes executing.

Question 86: You have a table named Table1 that contains the information from a sales invoice. For Tablel, you need to create a method named Tax Amount that will return the total amount of tax for the invoice. The method will be used in a report to show the tax amount information. Which type of method should you use? A) Static B) Accessor C) Main D) display

Explanation: Static methods, or class methods, belong to a class and are created by using the keyword static. They are called by using the following syntax: ClassName::methodName(); You do not need to instantiate an object before you use static methods. Static methods are widely used in Microsoft Dynamics AX to work with data that is stored in tables. Reference: Methods in X++ [AX 2012]

Question 57: You plan to create two tables named Table1 and Table2. Both tables will have a field named Customer Number of the string type that has a length of 15. The tables will have a relationship on the Customer Number field. You need to ensure that the string length of Customer Number is identical for both tables. The solution must ensure that if any relationships on the Customer Number field are added to other tables, the other tables will have the same string length for Customer Number. What should you use? A) A view B) An extended data type (EOT) C) A perspective D) A map

Explanation: Extended data types (EDTs) are user-defined types, based on the primitive data types boolean, integer, real, string, and date, and the composite type container. You can also base EDTs on other EDTs. The benefits of EDTs are as follows: Code is easier to read because variables have a meaningful data type. For example, Name instead of string. The properties you set for an EDT are used by all instances of that type, which reduces work and promotes consistency. For example, account numbers (AccountNum data type) have the same properties throughout the system. You can create hierarchies of EDTs, inheriting the properties that are appropriate from the parent and changing the other properties. Reference: Extended Data Types (EDTs) [AX 2012] Incorrect: Not C: A perspective is a collection of tables and views that contain the measures and dimensions for a cube. Not D: Maps define X++ elements that wrap table objects at run time. With a map, you associate a map field with a field in one or more tables. This enables you to use the same field name to access fields with different names in different tables. Map methods enable you to create or modify methods that act on the map fields.

Question 39: You need to identify which permission can be set only on a form that has date effective data. Which permission should you identify? A) Correct B) Create C) Delete D) Read E) Update

Explanation: For example, you have a role where you set the PastDataAccess property to Read, the CurrentDataAccess to Update, and FutureDataAccess to Delete. The role also includes a privilege that contains a permission to a valid time state table where the EffectiveAccess property is set to Correct. As a result, the role has read access to past records, update access to current records, and correct access to future records. Note: To grant access to the records in a valid time state table, you use the role-based security. You can specify whether a role can view, create, or update records in the table. * When you add date effective fields to a form, you use one of the following patterns. Show the current value. Show a list of editable records. Show a read-only list of records. Reference: Date Effective Data Sources for Forms [AX 2012]

Question 9: You have a table named VendTable that contains a field named MainContactWorker. MainContactWorker is the reference Recid. Many records in the VendTable table have the same value for MainContactWorker. Users frequently search for data in the Vend Table table based on the Main Contact Worker field. You need to ensure that when the users create queries that include the Main Contact Worker field in the where clause, the query results are returned in the least amount of time possible. What should you create in Vend Table? A) A unique index in Main Contact Worker B) A surrogate key that is used as the primary index C) A primary index for Main Contact Worker D) A non-unique index in Main Contact Worker

Explanation: For new tables the default is a primary key based on the RecId field. This is represented as the surrogate key in the user interface. PrimaryIndex: contains the surrogate key plus every index on the table that has its AlternateKey property set to Yes. Note: If you store surrogate foreign key values in your tables, you will have to correctly work with these values in your Enterprise Portal integration. This involves creating a reference data source to link to the data that is accessed by the surrogate foreign key. It can also include using the AxReferenceField to access the surrogate foreign key value. Reference: Table Keys: Surrogate, Alternate, Replacement, Primary, and Foreign [AX 2012]

Question 84: Last Name is a field in a table. The length of the field is modified at different layers as follows: At the SYS layer, the field is set to 20 characters. At the USR layer, the field is set to 60 characters. At the CUS layer, the field is set to 40 characters. At the VAR layer the field it is set to 10 characters. At runtime, what will be the length of the Last Name field? A) 40 B) 10 C) 20 D) 60

Explanation: In Microsoft Dynamics AX, a layer system is used to manage elements. The USR layer is the top layer and the SYS layer is the bottom layer, and each layer has a corresponding patch layer above it. The AOS manages layer flattening or overshadowing at runtime. That is, when you make an object modification in one layer, the modification overshadows the object on a lower layer at runtime. You could, for example, decide to change a caption on a standard form. The change is saved on your layer only, and the revised--or flattened--form replaces the standard form at run-time. Reference: Model store architecture [AX 2012]

Question 74: Last Name is a field in a table. The length of the field is modified at different layers as follows: At the SYS layer, the field is set to 20 characters. At the USR layer, the field is set to 60 characters. At the CUS layer, the field is set to 40 characters. At the VAR layer the field it is set to 10 characters. At runtime, what will be the length of the Last Name field? A) 40 B) 10 C) 20 D) 60

Explanation: In Microsoft Dynamics AX, a layer system is used to manage elements. The USR layer is the top layer and the SYS layer is the bottom layer, and each layer has a corresponding patch layer above it. The AOS manages layer flattening or overshadowing at runtime. That is, when you make an object modification in one layer, the modification overshadows the object on a lower layer at run-time. You could, for example, decide to change a caption on a standard form. The change is saved on your layer only, and the revised--or flattened--form replaces the standard form at run-time. Reference: Model store architecture [AX 2012]

Question 64: Last Name is a field in a table. The length of the field is modified at different layers as follows: At the SYS layer, the field is set to 20 characters. At the USR layer, the field is set to 60 characters. At the CUS layer, the field is set to 40 characters. At the VAR layer the field it is set to 10 characters. At runtime, what will be the length of the Last Name field? A 40 B 10 C 20 D 60

Explanation: In Microsoft Dynamics AX, a layer system is used to manage elements. The USR layer is the top layer and the SYS layer is the bottom layer, and each layer has a corresponding patch layer above it. The AOS manages layer flattening or overshadowing at runtime. That is, when you make an object modification in one layer, the modification overshadows the object on a lower layer at runtime. You could, for example, decide to change a caption on a standard form. The change is saved on your layer only, and the revised--or flattened--form replaces the standard form at run-time. Reference: Model store architecture [AX 2012]

Question 35: You need to add a conditional statement into a query object. Which class should you use? A) Query Item B) Query Build Data Source C) Query D) Query Range

Explanation: In Microsoft Dynamics AX, you can create a query to retrieve data by using the query classes. Note: The Query class enables you to create, read, update, and delete X++ code and metadata. The Query class embodies the structure of a query. Objects of this type are not used for fetching records from the database. Instead, use a QueryRun object that may be assigned a query object. The dynamic behavior of a query is defined by the . The static behavior is defined by the Query class. Queries contain one or more data sources that correspond to tables in the database. The data sources are specified by using QueryBuildDataSource objects. Incorrect Not B: The QueryBuildDataSource class provides the building blocks that queries are made of. Data sources are arranged in hierarchies that define the sequence in which records are fetched from the tables that are assigned to the data sources. Each data source defines the order in which the records are fetched, and also the criteria that must be met by the selected records. This class lets you create, read, update, and delete X++ code and metadata. Not D: Query range value expressions can be used in any query where you need to express a range that is more complex than is possible with the usual dotdot notation (such as 5012..5500). Reference: How to: Create Queries by Using X++ [AX 2012]

Question 51: Your company is performing a security audit. You need to provide a list of all the roles that have access to a form named Forml. What should you do? A) From the Dynamics AX client open System administration, click Common, click Users, and then click Users B) From the File menu of the Dynamics AX client, click Tools and then click Options C) From the Application Object Tree (AOT), right-click Form l, click Add-ins click Security tools, and then click View related security roles. D) From the Application Object Tree (AOT), open Security, right-click a role, click Add-ins. click Security tools, and then click View related security objects.

Explanation: In the AOT, shortcut menus are available on some Application Object Tree (AOT) nodes to find security objects and roles that are related to a particular node. For the example of duties, the following list describes the typical menu actions: 1. In the AOT, expand Security > Duties. 2. Right-click any one duty node, and then click Add-Ins > Security tools. 3. At the last level of the shortcut menu, click either View related security objects or View related security roles. 4. Examine the rows in the grid control on the form that is displayed. Example: Form: Related Roles The following image is an example of the form that is displayed when you click the shortcut menu option View related security roles for a node under AOT > Security > Duties. Reference: How to: Find Objects and Roles <image> Related to Security Constructs [AX 2012]

Question 42: You are developing X++ code to retrieve data from a table named Table1. You need to use a select statement to retrieve only records from Table1 that have related records in a table named Table2. Which type of join should you use? A) Inner B) Exists C) Outer D) Not exists

Explanation: InnerJoin: - Combined data source select the record from the main table that matches records in the joined table and vice versa. There is one record for each match. Records without related records in the other data source are eliminated from the result. Reference: Link Type and Join Types in ax 2012

Question 59: You have two data sources named Items and Item Details. There is a relationship between the data sources. Item Details contains detailed information about each item in Items. You plan to create a form that contains two grids. You need to configure the form to display the details of an item when the item is selected. What should you set? A) The Link Type of Items B) The Join Source of Items C) The Link Type of Item Details D) The Join Source of Item Details

Explanation: Item Details is the Child data source. We set the Join Source on the Item Details to Items. See step 5 below. Note: You can use form data sources to join tables that create a parent/child relationship between data records. Typically, the records from the data sources are visually separated on the form. For example, you use a grid to list order records and a second grid that us lists the order lines associated with each order. The following steps show how to add and join the tables. To Join Data Sources that Create Parent/Child Links 1. In the AOT, expand the form, and then expand the Data Sources node. 2. Press CTRL-D to open a second AOT, expand Data Dictionary, and then expand Tables. The AOT lists the tables you can use as a form data source. 3. To add tables to the form data source, drag two tables and drop each table on the Data Sources node of the form in the first AOT. The tables are added as data sources to the form. 4. Identify the table you will use as the parent data source. The other table will be the child data source. 5. Set the JoinSource property on the child data source to the name of the parent data source. 6. Set the LinkType property of the child data source to Active, Passive, or Delayed. The LinkType property specifies how to update the child data source in response to a change in the parent data source. 7. Create the form design, and then add fields from each data source to the form. Typically, you add two grid controls. One grid displays fields from the parent data source. The second grid displays fields from the child data source. Reference: How to: Join Parent/Child Data Sources for a Form [AX 2012]

Question 17: A table named Table 1 has a string field named Account Num. You have an instance of Table1 named table1. You need to print the value of Account Num to the info log. Which code segment should you use? A) Info (tablel. Get Account Num ( )); B) Info (tablel Account Num()); C) Info (int2str (tablel. Account Num)); D) Info (tablel. Account Num);

Explanation: Just reference using the standard tablename.tablefield syntax.

Question 25: You need to identify the output of the following X++ statement: Int counterA = 3; ; While(counterA mod 2) > 0) { Print strfmt("%1", counterA * (counterA mod 2)); If(counterA>=7) { break; } counterA+=2; } Pause; What should you identify? A) 3 B) 3 C) 4 D) 3

Explanation: MOD: Integer remainder Returns the remainder of an integer division of expression1 by expression2. Reference: Arithmetic Operators [AX 2012]

Question 46: You need to explicitly request permission to invoke a secured class. Which two methods should you use? Each correct answer presents part of the solution. A) Set B) Define C) Assert D) Invoke E) Demand

Explanation: Method assert: Declares that the calling code can invoke an API that is protected by a permission. Method Demand: Checks the call stack to determine whether the permission that is required to invoke an API has been granted to the calling code. Reference: ExecutePermission Class [AX 2012]

Question 12: You are developing a class named Classl that performs several calculations. One of the methods in Classl is named method1. Other developers will create classes that inherit from Classl. You need to ensure that methodl is available to Classl and to all of the classes that inherit Class The developers must not be able to call methodl from any other classes. Which keyword should you use to define methodl? A) Protected B) Public C) Server D) Private

Explanation: Methods that are declared as private can be called only from methods in the class where the private method is declared. Reference: Method Modifiers [AX 2012]

Question 58: You are planning the Dynamics AX architecture for a company that has two legal entities. You need to recommend a solution that meets the following requirements: Application logic must be shared between the two legal entities. Integration ports must be shared between the two legal entities. Data must not be shared between the two legal entities. W hat should you recommend creating? A) Two separate Dynamics AX instances that each has one data partition and one legal entity B) One Dynamics AX instance that has one data partition and two legal entities C) One Dynamics AX instance that has two Application Object Server (AOS) instances with a legal entity for each AOS instance D) One Dynamics AX instance that has two data partitions with one legal entity in each partition

Explanation: Microsoft Dynamics AX 2012 R2 enables data isolation by using data partitions. For example, an organization has several subsidiaries. If the management of the organization does not want employees of one subsidiary to have access to the data for other subsidiaries, data partitions can provide the boundaries that are required for data isolation. Reference: Data partitioning architecture [AX 2012]

Question 48: You need to assign the Accounts receivable manager role to a user. From where should you assign the role to the user? A) Local Users and Groups on a client computer B) The Security node in the Application Object Tree (AOT) C) The Site Permissions page in the Dynamics AX Enterprise Portal D) The Users form from the System administration module

Explanation: Microsoft Dynamics AX AOT allows the developer to manage role-based security. Under AOT > Security the developer manages permissions, privileges, duties, roles, and policies. Reference: Role-based Security in the AOT for Developers [AX 2012]

Question 3: You have two tables named Tablel and Table2. There is a many-to-one relationship between Table2 and Tablel. You discover that the following X++ statement is very slow to execute; Tablel field cannot have duplicate data in Table1. You need to reduce the amount of time it takes for the code to execute. What should you create? A) A unique index in table 1 Field and a unique index in table2.ref Field B) A non-unique index in table 1 Field and a unique index in table2.ref Field C) A unique index in table 1 Field and a non-unique index in table2 ref Field D) A non-unique index in table 1 Field and a non-unique index in table2 ref Field

Explanation: Put a unique index on the one-side field of the relation, that is on Table1. Put a non-unique index on the many-side field of the relation, that is on Table2.

Question 52: You are developing logic that will use a query object to fetch data from a database. Which function should you use to validate that the elements of type query exist in the Application Object Tree (AOT)? A) Query Build Data Source B) Query C) QueryStr D) QueryRun

Explanation: QueryStr retrieves a string that represents an existing query. This function is a compile-time function, which is a metadata assertion function. Compile-time functions take arguments that represent entities in the Application Object Tree (AOT) and validate these arguments at compile time. They have no effect at run time. Incorrect: Not D: The QueryRun class traverses tables in the database, fetches records that satisfy constraints that are given by the user, and helps to gather such constraints from user input. Reference: queryStr Function [AX 2012]

Question 43: You make changes to the security configuration of a role. You need to ensure that the changes appear in the Application Object Tree (AOT) immediately. What should you select from the Caches menu? A) Refresh data B) Refresh dictionary C) Refresh report server D) Refresh elements

Explanation: Refresh dictionary Flushes cached application object information for items in the Data Dictionary node of the AOT. Use this when you have made changes to resources in the Data Dictionary node, such as tables or extended data types, but the changes are not immediately reflected in Enterprise Portal. Incorrect: Not A: Refresh data Flushes cached database records. Use this when changes in the database are not immediately reflected in Enterprise Portal. Not C, not D: No such refresh commands. Reference: Troubleshooting: Enterprise Portal Development [AX 2012]

Question 56: You have a form that displays a list of items from a table named Table1. You need to prevent all users from updating the records by using the form. What should you modify? A) The table field groups B) The menu items C) The form template D) The data source

Explanation: Role-based security in Microsoft Dynamics AX The security model is hierarchical, and each element in the hierarchy represents a different level of detail. Permissions represent access to individual securable objects, such as menu items and tables. Incorrect: Not A: Field groups make it easier to create a logical layout in a form or report in a number of ways: A whole group of fields can be added to a form or report in one step instead of moving them individually. The field group can be given a label that is displayed on the form. It's easier to update forms and reports using field groups because a change to a field group is re- flected in all the forms and reports that use it.

Question 36: What can you prevent an object from accessing by using a display method authorization? A) Data from forms B) Data from jobs C) Data from reports D) Data from tables

Explanation: Security for display and edit methods can be enforced on forms. Reference: Security on Display and Edit Methods [AX 2012]

Question 66: You have a table named Table1 that contains the information from a sales invoice. For Table1, you need to create a method named Tax Amount that will return the total amount of tax for the invoice. The method will be used in a report to show the tax amount information. Which type of method should you use? A) Static B) Accessor C) Main D) display

Explanation: Static methods, or class methods, belong to a class and are created by using the keyword static. They are called by using the following syntax: ClassName::methodName(); You do not need to instantiate an object before you use static methods. Static methods are widely used in Microsoft Dynamics AX to work with data that is stored in tables. Reference: Methods in X++ [AX 2012]

Question 76: You have a table named Table1 that contains the information from a sales invoice. For Table1, you need to create a method named Tax Amount that will return the total amount of tax for the invoice. The method will be used in a report to show the tax amount information. Which type of method should you use? A) Static B) Accessor C) Main D) display

Explanation: Static methods, or class methods, belong to a class and are created by using the keyword static. They are called by using the following syntax: ClassName::methodName(); You do not need to instantiate an object before you use static methods. Static methods are widely used in Microsoft Dynamics AX to work with data that is stored in tables. Reference: Methods in X++ [AX 2012]

Question 24: You are developing a solution to insert and update records in a table named Table1. Table1 is structured as shown in the following table. ID (Int)|Description (String 60) 1|Record 1 2|Record 2 3|Record 3 4|Record 4 You have the following X++ code: Int counter = 3, maxValue = 4; Table1 table1; try { for(counter = 3; counter<6; counter++) { table1.clear(); table1.ID = counter; table1.Description = strfmt("Record %1", counter); table1.insert(); If(Counter == maxValue) { Info("Max value"); break; } } } catch(Exception::Error) { Info("Error"); } catch(Exception::DDEerror) { Info("Data error"); } catch(Exception::Break) { Info("Break"); } You need to identify the output of the X++ code. What should you identify? A) Error B) Max value C) Break D) Data error

Explanation: The code will run fine. New lines will be inserted into the table. Note: * clear method Deletes the data and the state information for a table object. W hen the clear method has been executed the records in the table hold NULL values. * insert method Executed when a new record is inserted into the table. If the record cannot be inserted, the super() call throws an exception. Reference: Table Methods [AX 2012]; Exception Handling with try and catch Keywords [AX 2012]

Question 13: You need to identify which elements the Reverse engineer tool will provide for a data model. Which three elements should you identify? Each correct answer presents part of the solution. A) Table methods B) Classes C) Table fields D) Base enumerations E) Extended data types (EDTs)

Explanation: The following table lists the elements that are included in the diagram for the UML data model: * (C) Table fields * (D) All base enums * (F) All extended data types Etc. Note: The Reverse Engineering tool can create the following types of UML models: * UML data model * UML object model Reference: Reverse Engineering Tool Overview [AX 2012]

Question 16: You have the following X++ code: (Line numbers are included for reference only.) 01 public class Class1 02 { 03 int variable1; 04 int variable2; 05 } 06 public int method1(int _variable1 = variable1) 07 { 08 variable1 = _variable1; 09 return variable1; 10 } 11 public int method2() 12 { 13 14 return variable2; 15 } 16 public class Class2 17 { 18 } 19 public void method3(Class1 class1Obj) { error("Process was canceled."); } 20 { 21 int variable3; 22 23 } methodl and method2 are in Classl. method3 is in Class2. You need to set the value of variable3 to the value of variablel from ClasslObj. Which code segment should you insert at line 22? A) variable3 = ClasslObj.methodl(); B) variable3 = new Classl().variablel; C) variable3 = ClasslObj.variable l; D) variable3 = this.variable l;

Explanation: The variable from the other class is only accessible through the method method1.

Question 28: You are developing a solution for a customer. You plan to add a local embedded function to perform a recursive operation by using the following code: Void mainMethod(str _mainMethodParam) { Int CounterInMainMethod; Void embeddedFunction(str _embeddedFunctionParam) { Int CounterInembededFunction; ; } ; } You need to identify which variables can be accessed from mainMethod. Which variables should you identify? A) MainMethodParam and embededFunctionParam B) MainMethodParam and CounterInMain Method C) EmbededFunctionParam and CounterInembeded Function D) CounterInMainMethod and CounterInembeded Function

Explanation: The variables local to the to embededFunction cannot be accessed by MainMethod.

Question 40: You need to create a new extensible data security (XDS) policy. What should you use? A) A map B) A part C) A query D) A job

Explanation: There are two stages in creating the XDS policy: Policy query Security policy. Reference: Microsoft Dynamics AX 2012 Security Policies Extensible Data Security (XDS)- Create a Policy Query

Question 23: You are developing a solution by using X++. The solution updates multiple records. You need to ensure that if the solution attempts to modify records that currently are being edited by a user, the operation will be retried. Which type of exception should you handle? A) Code Access Security B) Sequence C) Update Conflict D) Deadlock

Explanation: Update Conflicts OCC makes it possible for other processes to update a record even after it has been fetched. You can catch update conflicts by catching the UpdateConflict and UpdateConflictNotRecovered ex- ceptions. Exception: UpdateConflict Indicates that an error has occurred in a transaction that is using Optimistic Concurrency Control. The transaction can be retried (use a retry statement in the catch block). Incorrect: Not D: Exception Deadlock: Indicates that there is a database deadlock because several transactions are waiting for each other. Reference: Optimistic Concurrency Control [AX 2012]; Exception Handling with try and catch Keywords [AX 2012]

Question 27: A developer writes code by using X++. You need to identify whether the code violates best practices. W hich tool should you use? A) The X++ code editor B) The Code profiler C) The X++ compiler D) The Debugger

Explanation: When using the Microsoft Dynamics AX development environment, you should adhere to a set of best practices. The X++ compiler checks the code for best practice issues. These issues can re- sult in best practice errors, warnings, or informational messages. Incorrect: Not B: The Code Profiler measures the execution time of individual lines of code. Use this tool to find performance bottlenecks and to help understand code that was developed by others. Reference: Best Practices for Microsoft Dynamics AX Development [AX 2012]

Question 4: You have two tables named Table1 and Table2. There is a relationship between the tables. You need to display data from both tables in a form. How should you create the data source for the form? A) Add both tables to a perspective and use the perspective as the data source. B) Create a new table named Table3 that is related to Table1 and Table2. Use Tables as the data source. C) Add both tables to a map and use the map as the data source. D) Add both tables to a query and use the query as the data source.

Explanation: You can add parent and child data sources to a query. Add multiple data sources to a query 1. In the Application Object Tree (AOT), click Queries, locate the query you want to add data sources to, and then click the query node. For information about create queries, see Accessing Data. 2. Right-click Data Dictionary, and then click Open New W indow. 3. Drag a table, map, or view from the new window to the Data Sources node below the query node to add a parent data source. 4. Click the parent data source, and then drag a table, map, or view from the new window to the Data Sources node below the parent data source to add a child data source. 5. Specify how the parent and child data sources are joined by setting the JoinMode property on the child data source 6. Create a relationship between the data sources. Reference: How to: Add Multiple Data Sources to a Query [AX 2012] Incorrect: Not C: Maps define X++ elements that wrap table objects at run time. W ith a map, you associate a map field with a field in one or more tables. This enables you to use the same field name to ac- cess fields with different names in different tables. Map methods enable you to create or modify methods that act on the map fields.

Question 15: You need to develop a solution to process accounts receivable. The solution must halt the process and display a message if the process starts before the last day of the month. The process must resume once the user acknowledges the message. Which communication statement should you use? A) Warning ("This process should only be started on the last day of the month"); B) Info ("This process should only be started on the last day of the month"); C) Box: warning ("This process should only be started on the last day of the month"); D) Error ("This process should only be started on the last day of the month"); E) Print "This process should only be started on the last day of the month";

Explanation: You can display a message in a modal dialog box by using the Box class. Box class static method name: warning The OK button is the only one displayed in the dialog box. Use this dialog box for a warning message. Example: diagBut = Box::Warning(strMessage, DialogButton::No, // Initial focus is on the No button. strTitle); Reference: Displaying a Message Box [AX 2012] Incorrect: Not B: The info method displays text in the Infolog window. Not E: X++ provides a print statement that allows you to display text or selected results in a temporary window. The messages are displayed in a Print window that appears when the first print statement is executed.

Question 29: You have a class named Class1. You need to identify all of the classes that extend Classl. Which tool should you use? A) The Type hierarchy browser B) The Tracing cockpit C) The Code profiler D) The Compare tool

Explanation: You can view information about the parents and children of application objects by using the Type Hierarchy Browser. For example, you can see all the classes that extend a particular class, or see which data types a particular extended data type inherits from. You can also see which types implement fields, methods, and properties. Reference: Type Hierarchy Browser and Type Hierarchy Context [AX 2012]

Question 50: You are writing logic to fetch data from a database. The logic will use a select statement. You need to identify which keyword to use to fetch a single record from the database. Which keyword should you use? A) FirstFast B) ForUpdate C) Exists D) FirstOnly

Explanation: firstOnly Speeds up the fetch. Instructs MorphX to fetch only the first record. Example: select firstFast custTable order by AccountNum; Reference: Select Statement Syntax [AX 2012]

Question 44: You are developing X++ code to update multiple records as a single transaction. The records are located in several tables. You need to ensure that if an update of one of the records falls, none of the records update. What should you use? A) Try and catch B) Tts begin and tts commit C) Insert record set and tts abort D) For update and tts abort

Explanation: ttsLevel Checking This check ensures that no record can be updated or deleted except from within the same transaction scope as it was selected for update. Integrity is ensured by using the following statements: * ttsBegin: marks the beginning of a transaction. This ensures data integrity, and guarantees that all updates performed until the transaction ends (by ttsCommit or ttsAbort) are consistent (all or none). * ttsCommit: marks the successful end of a transaction. This ends and commits a transaction. MorphX guarantees that a committed transaction will be performed according to intentions. * ttsAbort: allows you to explicitly discard all changes in the current transaction. As a result, the database is rolled back to the initial state--nothing will have been changed. Typically, you will use this if you have detected that the user wants to break the current job. Using ttsAbort ensures that the database is consistent. Reference: Transaction Integrity [AX 2012]

Question 22: You have the following X++ statement: Int counter = 4; ; Do { while(counter>=3) { print strfmt("%1", 2); break; } print strfmt("%1", counter); counter--; } While(counter >= 3); Pause; You need to identify the output of the statement. What should you identify? A) 2 B) 4 C) 2 D) 2

no answer given


Ensembles d'études connexes

Fluid and Electrolytes chapter 13 #1

View Set

Introduction to AI key facts and definitions

View Set

4.2 Niches and Community Interactions WS

View Set

BIO121 Intramembranous Ossification

View Set

Grade 11 accounting for Depreciation Review

View Set