Monthly Archives: July 2014

Error while Opening AX 2012 R2 Retail POS: could not load all external service modules

It is a common error for AX 2012 R2 POS screen, whenever we setup device information on hardware profile and run the N-jobs, this error usually appears on POS screen and it won’t let you open POS.


Connector TestConnector not found!

SystemCore: System.Exception: Processor not found.
at Microsoft.Dynamics.Retail.SDKManager.PaymentProcessorManager.GetPaymentProcessor(String name)
at Microsoft.Dynamics.Retail.Pos.EFT.PaymentSDKProcessor.GetEftPaymentProcessor(String connectorName)
at Microsoft.Dynamics.Retail.Pos.EFT.PaymentSDKProcessor.GetEftProcessorServices(String connectorName)
at Microsoft.Dynamics.Retail.Pos.EFT.EFT.Initialize()
at Microsoft.Dynamics.Retail.Pos.SystemCore.Services.Initialize()
at Microsoft.Dynamics.Retail.Pos.SystemCore.PosApplication.Initialize().


The solution I found is simple by copying TestConnector DLL to Retail folder.

1. Copy the Microsoft.Dynamics.Retail.TestConnector.dll from “C:\Program Files (x86)\Microsoft Dynamics AX\60\Client\Bin\Connectors”

2. Paste the Microsoft.Dynamics.Retail.TestConnector.dll to “C:\Program Files (x86)\Microsoft Dynamics AX\60\Retail POS\Connectors”

3. Open POS, Problem solved


Converting Managed Solutions to Unmanaged Solutions CRM 2013

Okay, so recently we needed to convert a managed solution into unmanaged solution to recover the lost files for Dynamics CRM 2013, but the question was HOW? Our unmanaged solution was lost and we were only left with the Managed solution.(I hope no one ever gets into this situation :) )
After Googling this issue (like we all do :) ) I found this solution which didn’t work in my case. It was for Dynamics CRM 2010.

1. Unzip the Managed Solution .zip file to your computer.
2. Open the ‘solution.xml’ file from within the Solution folder.
3. Find the <managed> tag on approximately line 9.
4. Change the value from ‘1’ (Managed) to ‘0’ (Unmanaged).

Editing the solution.xml

5. Save the ‘solution.xml’ file.
6. Zip the solution again by selecting all the files within the solution folder and either using WinRAR or simply by right clicking and selecting Send to > Compressed (zipped) folder.
7. The Zip file that gets created is the new Unmanaged Solution file. Import this into CRM as usual to start using the Unmanaged Solution.

 Sadly, this didn’t work!

THEN I found another interesting yet risky way of doing this for Dynamics CRM 2010 and tried to give it a shot This technique was demonstrated at TechED 2012, but I wasn’t sure if it would work for Dynamics CRM 2013 or not. AND IT WORKED! :)

Following are the steps to convert a managed solution to unmanaged one:

1. Create a new staging organization in Dynamics CRM 2013 (lets say StagingOrg)

2. Import the managed solution you want to convert to unmanaged in this Organization (StagingOrg).

3. Now connect SQL server from the database of StagingOrg and run this Query after changing the name of your managed solution accordingly.

declare @solutionId uniqueidentifier, @systemSolutionId uniqueidentifier

-- specify the uniquename of the managed solution you'd like to unmanage here it is StagingOrg
select @solutionId = solutionid from SolutionBase where UniqueName='StagingOrg'

select @systemSolutionId = solutionid from SolutionBase where UniqueName='Active'

update PublisherBase set IsReadonly=0 
	where PublisherId in (select PublisherId from SolutionBase where SolutionId=@solutionId)

print 'updated publisher'

-- tables below will be captured by the generic looper
--update SolutionBase set IsManaged=0 where SolutionId=@solutionId
--print 'updated publisher and solution'

--update PluginAssemblyBase set IsManaged=0 where SolutionId=@solutionId
--update PluginTypeBase set IsManaged=0 where PluginAssemblyId in (
--	select PluginAssemblyId from PluginAssemblyBase where SolutionId=@solutionId
--update SdkMessageProcessingStepBase set IsManaged=0 where SolutionId=@solutionId
--update SdkMessageProcessingStepImageBase set IsManaged=0 where SolutionId=@solutionId
--print 'updated plugins and messages'

--update WebResourceBase set IsManaged=0 where SolutionId=@solutionId
--print 'updated web resources'

--delete from DependencyBase where DependentComponentNodeId in (
--	select DependencyNodeId from DependencyNodeBase where BaseSolutionId=@solutionId

--alter table DependencyBase NOCHECK CONSTRAINT dependencynode_ancestor_dependency 
--delete from DependencyNodeBase where BaseSolutionId=@solutionId
--alter table DependencyBase CHECK CONSTRAINT dependencynode_ancestor_dependency
--print 'removed dependencies'

declare @tables table (id int identity, name nvarchar(100), ismanaged bit, issolution bit)
declare @count int, @currentTable nvarchar(100), @currentM bit, @currentS bit, @sql nvarchar(max)

-- go through all the tables that have the ismanaged/solutionid flag, find the related records for the current solution and move them to the crm active solution.
insert into @tables (name, ismanaged, issolution)
	select name, 1, 0 from sysobjects where id in 
		(select id from syscolumns where name in ('IsManaged')) 
	and type='U'
	order by name
insert into @tables (name, ismanaged, issolution)
	select name, 0, 1 from sysobjects where id in 
		(select id from syscolumns where name in ('SolutionId')) 
	and type='U' and name not in ('SolutionComponentBase') -- ignore this table because it doesn't make a difference. it does cause dependency errors on the exported solution but we can manually edit the xml for that.
	order by name
select @count = count(*) from @tables
while (@count > 0)
	select @currentTable =name, @currentM =ismanaged, @currentS =issolution from @tables where id=@count
	if (@currentM = 1) 
		select @sql ='update ' + @currentTable + ' set IsManaged=0 where SolutionId=N''' + cast(@solutionId as nvarchar(100)) + ''''
		exec (@sql)
		print 'updated IsManaged to 0 on: ' + @currentTable
	if (@currentS = 1)
		select @sql ='update ' + @currentTable + ' set SolutionId=N''' + cast(@systemSolutionId as nvarchar(100)) + ''' where SolutionId=N''' + cast(@solutionId as nvarchar(100)) + ''''
		exec (@sql)
		print 'updated SolutionId on: ' + @currentTable
	select @count = @count -1, @currentTable = NULL

4. It will show some errors after running the script. I ignored them.

5. Now go into Settings > Customizations > Solutions > and export the solution as Unmanaged. Notice that it has become Unmanaged from managed now.

6. Save the zip file and extract it to a folder

7. Open the solution.xml file from the folder and search MissingDependency tag.

8. You will notice lot of MissingDependency elements, remove them all and self close the MissingDependency tag like this <MissingDependency />

9. Zip the files again and now import it to your development environment. Now you can import it as managed or unmanaged wherever you want.

Cheers! :)

Catch Weight Functionality for Receiving of Goods in Microsoft Dynamics AX 2012

Many industries receive raw material in a different packaging unit, while payment may be made in a different unit. This post will help you understand how to receive product in different packaging using Catch Weight. Let’s take an example of cotton in Textile Industry, Cotton is received in unit “Bales” and normally companies need to pay the vendor after weighing in Kilograms. This weight may be different in each case because the Bale has a catch weight. Users face great difficulties while receiving goods because in AX 2012 we can give only one Unit of Conversion against single item. Lets have a look on how to resolve this:

First of all go to Product Information Management –> Common –> Released Product then click on New

Do not forget to mark CW Product Check Box while creating new Product


Then click OK button and you can see the New Product in Product Information Management


New Item

Define unit of conversion of Product; remember that we have taken Inventory and Purchasing unit “KG”

Unit of Conversion


After setting unit of conversion go to the Product and edit that then go to Manage Inventory tab and select catch weight unit as Bales

Edit Prduct

and add minimum and maximum quantity to be received. Note that minimum and maximum quantity will be the quantity to be received in Kilograms not bales

Setups have been done. Now, we need to receive the same Product for this follow the below navigation

Go to Procurement & Sourcing –> Common –> Purchase Orders –> All Purchase Orders then click on New PO


Select vendor and click Okay

Then select the Product on Purchase order lines

PO Lines

After taking Product and its quantities click on Update Line tab and select Registration

Update Line

This will be done after confirmation of Purchase order and before Receiving of Goods but at this stage user must know the actual weight of the Product which user is going to receive.

Now click on Auto create

Auto Create

After clicking on Auto Create checkbox, the total quantity of that Product will copy in Register now

Now user can register the actual weight of the goods received. Let’s say we have set the conversion from Bales to Kilograms 150 kg but at the time of receiving when Product was measured on weighing bridge user came to know that actual conversion is 1 Bale = 200 kilograms then here user will register the quantity with actual weight even batch number wise

Batch Wise registeration

But registration is only based on minimum and maximum quantities setup on Catch Weight you can see in the above screen shot that setup conversion was 150 kilogram but registration has been done with 200 kilograms conversion

After this go to the Product Receipt for receiving the Product

Product Receipt 1

Enter Product Receipt number

Product Receipt 2

In above Posting Product Receipt screen you can see on lines The CW quantity remains same but conversion factor has been changed from 150 kg conversion to registered 200 kg conversion

Now click Ok for receipt.

Now you can check “On Hand” inventory will show the inventory of received product

On Hand

You can see the receiving of goods in different batches with actual weight of the Product received.

Hope this post will help to solve the Catch Weight receiving issues that you may have.