20 November 2014

SSRS: Report labels only IDs

The report labels do not display, or the report shows label IDs, like Labels!@SYS24426 instead of the label values:

Searching for this issue you will find the following technet solution:

The SSRS Service Account password could be invalid.
  1. From the Start menu, point to All Programs, click the SQL Server folder, click the Configuration Tools folder, and then click Reporting Services Configuration Manager.
  2. In Reporting Services Configuration Manager click Connect and then click Service Account.
  3. Set the password and then click Apply. The account and password should be the same as the Microsoft Dynamics AX proxy account. For more information, see Before you install the Reporting Services extensions.
  4. Click the ServerName/MSSQLSERVER and then click Stop. Then click Start to restart the server. Always check with the SQL administrator and make sure no other users are connected to the server before you restart the server.
In my case this was not the issue. Instead it was a misconfiguration of the SSRS instance. In the RSReportServer.config there was a line missing in the <Service> element:

After adding this part everything works fine again.

So keep in mind to also check the configuration of the SSRS installation. A missconfiguration could also lead to these label issues.

19 November 2014

Delete Transactional Data in a company

There is a class in AX that helps deleting transactional data. You'll find it in the AOT (Ctrl + D) in the classes node: SysDatabaseTransDelete.
Run this class by opening the main method and press (F5). It will prompt you to delete transactions in the current company.

 It will delete all tables with tablegroup:
  • Transaction
  • WorksheetHeader
  • WorksheetLine 
  • Except (CustCollectionLetterLine, InventDim, DocuRef, DirPartyRelationship). 
It will skip all global tables expect (SpecTrans and GeneralJournalEntry).
In addition to the transactional tables it will delete:
  • SalesTable 
  • PurchTable 
  • WMSPallet 
  • CustInterestJour 
  • CustCollectionLetterJour 
  • ProjControlPeriodTable 
  • ProjInvoiceJour 
  • ProjJournalTable 
  • PdsRebateTable 
  • PdsBatchAttributes 
 The execution takes a while depending on the amount of transactional data in the current company.

14 November 2014

DIXF: Unable to update records

I recently experienced an issue where I was not able to update records through the data Import export framework. While running the "copy data to terget" step I got a stacktrace in the DMFEntityWriter.write() method in

line 224: if (foundRecord && qRun.changedNo(currentNode.QuerySequenceNo))

After some comparissons with other environments I found out that the target entity was missing a table in the target entity hierarchie.
To solve this issue open the target entity form and click on change target mapping. In that form click details and regenerate the mapping. That also updates the hierarchie and the update is working fine again.

13 November 2014

Security development tool bug in setup class

When installing the Dynamics AX Security Development Tool it is required to run the main method of the class SysSecEntryPointManager to add the Menu Items to the Menu and the ContextMenu. But there is a bug in this method :(

You must run the setup class in english due to the fact that the developer of the main method has forgotten to use the labels :)

If you don't want to switch the language replace the following lines:

Line 39: menuNode = systemAdministrationNode.AOTfindChild('@SYS333869'); //SETUP
Line 42: menuNode = menuNode.AOTfindChild('@SYS334421'); //Security
Line 72: menuNode = sysContextMenuNode.AOTfindChild('@SYS310448');//Security tools

12 November 2014

DIXF: not compatible with SQL 2012 SP2

If you try to import data with the data import export framework and you recieve the following error message:

System.ServiceModel.CommunicationException: Fehler beim Empfangen der HTTP-Antwort für http://AXSQLSERVER:7000/DMFService/DMFServiceHelper.svc. Die Ursache kann sein, dass die Dienstendpunktbindung kein HTTP-Protokoll verwendet. Eine andere mögliche Ursache ist, dass der HTTP-Anforderungskontext vom Server abgebrochen wird (vermutlich auf das Herunterfahren des Diensts zurückzuführen). Weitere Informationen finden Sie in den Serverprotokollen. ---> System.Net.WebException: Die zugrunde liegende Verbindung wurde geschlossen: Unbekannter Fehler beim Empfangen.. ---> System.IO.IOException: Von der Übertragungsverbindung können keine Daten gelesen werden: Eine vorhandene Verbindung wurde vom Remotehost geschlossen. ---> System.Net.Sockets.SocketException: Eine vorhandene Verbindung wurde vom Remotehost geschlossen
   bei System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   --- Ende der internen Ausnahmestapelüberwachung ---
   bei System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   bei System.Net.PooledStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   bei System.Net.Connection.SyncRead(HttpWebRequest request, Boolean userRetrievedStream, Boolean probeRead)
   --- Ende der internen Ausnahmestapelüberwachung ---
   bei System.Net.HttpWebRequest.GetResponse()
   bei System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)
   --- Ende der internen Ausnahmestapelüberwachung ---

Server stack trace:
   bei System.ServiceModel.Channels.HttpChannelUtilities.ProcessGetResponseWebException(WebException webException, HttpWebRequest request, HttpAbortReason abortReason)
   bei System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)
   bei System.ServiceModel.Channels.RequestChannel.Request(Message message, TimeSpan timeout)
   bei System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
   bei System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
   bei System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

Exception rethrown at [0]:
   bei System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
   bei System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
   bei Microsoft.Dynamics.AX.DMF.ServiceProxy.DMFServiceReference.ServiceContract.ShowPreview(DMFEntity entity)
   bei Microsoft.Dynamics.AX.DMF.ServiceProxy.DmfEntityProxy.DoWork[T](Func`1 work)

You will notice that the DIXF service has crashed, Check the Version of the SQL Server. If you are running SQL Server 2012 with SP2 (11.0.5058.0) or even SP2 CU1 (11.0.5532.0) you need to update to CU2 (11.0.5548.0) -

11 November 2014

DIXF: File or Assambly not found

Client Error:

If you get the following message in the infolog. Check if the client components of the data import export framework are installed for the current client.

Die Datei oder Assembly "Microsoft.Dynamics.AX.DMF.PreviewGrid, Version=, Culture=neutral, PublicKeyToken=31bf3856ad364e35" oder eine Abhängigkeit davon wurde nicht gefunden. Das System kann die angegebene Datei nicht finden.

Therefor navigate to the Dynamics AX client\bin folder and search for Microsoft.Dynamics.AX.DMF.*. There should be at least four dll files. If not reinstall the client components or copy the files from another client Folder.

Server Error:

If there is no Service URL in the Data Import Export Parameter form and the infolog is showing the following error:

Auf die Assembly, die Typ Microsoft.Dynamics.AX.DMF.ServiceProxy.DmfEntityProxy enthält, wird nicht verwiesen. Objekt 'CLRObject' konnte nicht erstellt werden.

If you get this error check if the DIXF (DMF) components for the AOS are installed:

  • For AX2012 R2 till CU6 use the DIXF package 
  • For AX2012 R2 CU7 install DIXF from the CU7 update package 
  • For Ax2012 R3 use the DIXF component that are provided by the R3 installation 
After the installation of the DIXF Components for the AOS Server restart the AOS!!!

DIXF: Parameters Service URL - Dienstverbindungs-URL

If you have problems with a wrong service url in the data import export framework Parameters there are 2 ways to change it:

You should navigate to the AX "Server/bin" folder and edit the Microsoft.Dynamics.AX.DMF.ServiceProxy.dll.config file. In this file you will see the xml tag for the endpoint address. There you can enter the correct address. That's it :) I restarted the AOS afterwards, but I'm not quite sure if this is necessary.

Another option is to unistall the DIXF AOS Component and reinstall it. During the installation you will be asked to enter the server name.

05 November 2014

Contoso demo environment license rearm

If the licence of your contoso demo environment is expiring you are able to rearm the license up to three times.

Therefor just open a command prompt with admin privileges and type the following command:

slmgr -rearm