posting an variant item to Ax Retail POS from .net

Hi All,

I am trying to post items to the retail transaction using blank operation from .net application.

I can post standard item using RunOperation(ItemSale,ItemId) method and RetailPosTransaction.Add(SaleLineItem) method.

But it does not work when the item has dimensions like Color,Size Style .

I have tried to create an object of SaleLineItem with dimensdetails as below

SaleLineItem item = new SaleLineItem();

item.ItemId = “0140”; //line.ItemId;

Dimensions dm = new Dimensions();

dm.VariantId = “VN-000234”;

dm.ColorId = “Black”;

dm.SizeId = “L”;

dm.ColorName = “Black”;

dm.SizeName = “Large”;

dm.DistinctProductVariantId = 22565421355;

item.Dimension = dm;

item.Quantity = 4; //line.Quantity;


but the Ax POS does not find this item.

Also I have tried the solution given at How insert an item into POS transaction CODE C#

Please let me know how to add variant item to POS,

Any help will be greatly appriciated.

Thanks in advance