How to change EDT and propagate this to AIF XML Schema (XSD).

Sometimes you have to change parameter of Extended data type which are also used by AIF. For example number of decimal digits etc. When you change this settings just in Dynamics AX AOT and save it, still you will have old values in generated XSD, that means any inbound message will be validated against old…

0

How to delete orphaned data remained from deleted company?

In AX 2009 it may happen that you delete a company but data related to this company remain in the database. You can use this script to delete this data: /* * Code Sample Disclaimer: * Microsoft provides programming examples for illustration only, * without warranty either expressed or implied, including, but not limited to,…

0

AX application files, locked by another process.

We have seen issues where the AX application files gets locked by others then the AOS process. This will cause the production  to stop, until the lock is removed. A typical application which causes the error is the Antivirus Software. Excluding the application folder should solve the issue. In case it is something else, or…

0

Database log error on AX 2009 with SQL Server 2008

On a database that is upgraded from AX 4.0 to AX 2009 running on SQL 2008 you may get following error while using database log: The target table ‘SYSDATABASELOG’ of the DML statement cannot have any enabled triggers if the statement contains an OUTPUT clause without INTO clause.. The SQL statement was: INSERT INTO SYSDATABASELOG…

1

How to move Demand Planner database to another server

Sometimes you need to move your existing Demand Planner database to another server. If you do this just using backup/restore, you will run into the issue while synchronizing the Demand Planner. The error you get is: Could not find ‘server name’ in sys.sysservers This is because Demand Planner uses fully qualified object names in some…

0

Conflict error when list of fields is used in select during update transaction

If you use this code, you will get an error on the line 29. The error message is following: Cannot edit a record in Table1 (Table1). An update conflict occurred due to another user process deleting the record or changing one or more fields in the record. 1: static void updateTable1(Args _args) 2: { 3:…

3

Error while calling Win API function on x64

When you are calling Win API function (or function from a native DLL) on x64 you get this error: An exception occurred when calling Function in Library name DLL library This happens only if the code calling the DLL function is running on server. The reason for this is that the DLLFunction class is not…

0

Rename object in TFS

You can get this error message while renaming object that is checked out from TFS. Unable to import Trying to import Table MFATable_test1 with ID 50003 ID already held by Table MFATable1 To rename the object you need to follow these steps: Right click the object in AOT and select Rename (without checking out the…

0

AX 2009 .NET Business Connector fails while creating instance of XmlDocument

RTM version (5.0.593.0) of .NET Business Connect fails with following exception while creating instance of XmlDocument class in X++ code. System.Runtime.InteropServices.SEHException: External component has thrown an exception. at AxCore_CallStatic(Char* , Char* , tagVARIANT* , Int32 , tagVARIANT* ) at Microsoft.Dynamics.BusinessConnectorNet.Axapta.CallStaticClassMethod(String className, String methodName, Object[] paramList) at Microsoft.Dynamics.BusinessConnectorNet.Axapta.CallStaticClassMethod(String className, String methodName) at BusinessLogic.DocumentationManager.GetXml() in D:\Development\AX\BC.NET Sample…

0

HOWTO: Print Word document from X++

You might need to print Word document directly from X++. Here’s a short sample how to do this:{ str document = “C:\\test.doc”; COM wordApplication; COM wordDocuments; COM wordDoc; ; // Create instance of Word application wordApplication = new COM(“Word.Application”); // Get documents property wordDocuments = wordApplication.Documents(); // Open document wordDoc = wordDocuments.Open(document); // Activate the…

0