AXForum  
Go Back   AXForum > Microsoft Dynamics AX > DAX Blogs
All
Forgotten Your Password?
Register Forum Rules FAQ Members List Today's Posts Search

 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old 13.09.2017, 17:11   #1  
Blog bot is offline
Blog bot
Участник
 
25,646 / 848 (80) +++++++
Join Date: 28.10.2006
Art Of Creation: Dynamics AX: No metadata class defined for data contract object
Источник: http://www.artofcreation.be/2014/03/...ntract-object/
==============

When creating and using services you can get the following error:
No metadata class defined for data contract object

When you get this error it means that you are trying to use a type as a data contract that is not a valid data contract type.
Valid type are primitive types, tables and views, data contracts, containers, EDT’s, and collections (For a full list of supported types, check the Using Data Contracts in X++ [AX 2012] page on msdn.

To figure out what data member is causing a problem, put a breakpoint at the throw error in the SysOperationDataContractInfo.newParameterInfo() method. When the breakpoint is hit, the data member will be displayed in the _parentMethodParameterName variable and the type in the dictClass variable.

To solve the problem, use a type that is supported. If you want to pass a class, either pass it as a container (e.g. using a pack() method), or better yet, define the class as a data contract with data members.

Note: I’ve also seen this error pop up when the data contract wasn’t correctly compiled. Simply put a breakpoint as described above to figure out what data contract is causing the problem and compile the class (both X++ and CIL). Keep in mind that you might have to compile forward if the class is extended, or do a compile forward on the class that it extends.



Источник: http://www.artofcreation.be/2014/03/...ntract-object/
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору.
 

Similar Threads
Thread Thread Starter Forum Replies Last Post
emeadaxsupport: AX Performance - Analyzing key SQL Server configuration and database settings Blog bot DAX Blogs 0 28.09.2015 14:11
crminthefield: Podcast and Overview: Microsoft Dynamics CRM 2011 Update Rollup 13 Blog bot Dynamics CRM: Blogs 0 27.03.2013 22:12
Dynamics AX на Convergence 2012 Blog bot Microsoft и системы Microsoft Dynamics 0 13.01.2012 10:52
daxdilip: Whats New in Dynamics AX 2012 (A brief extract from the recently held Tech Conf.) Blog bot DAX Blogs 7 31.01.2011 12:35
Developer for Microsoft Dynamics AX Certification Roadmap Blog bot DAX Blogs 1 13.05.2009 16:17

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Рейтинг@Mail.ru
All times are GMT +3. The time now is 00:50.
Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Contacts E-mail, Advertising.