AXForum  
Вернуться   AXForum > Microsoft Dynamics AX > DAX Blogs
All
Забыли пароль?
Зарегистрироваться Правила Справка Пользователи Сообщения за день Поиск Все разделы прочитаны

 
 
Опции темы Поиск в этой теме Опции просмотра
Старый 11.02.2018, 02:41   #1  
Blog bot is offline
Blog bot
Участник
 
25,459 / 846 (79) +++++++
Регистрация: 28.10.2006
doens.be: Ax2009 Event Processing Error
Источник: https://www.doens.be/2012/02/ax2009-...cessing-error/
==============

I have a customer that gets a error every time the EventJobCUD-batch (Change Based Events) runs. They got the following error:


After some reseach I found out that when 2 fields are changed at the same time, you go several times through the listChangedFieldsEnumerator (location ClassesEventProcessorCUDprocessUpdate)

while (listChangedFieldsEnumerator.moveNext()){ // In this simple case we use the new and the original changed field value as // recorded at event detection time: [thisFieldId, changedFieldValue, origChangedFieldValue] = listChangedFieldsEnumerator.current(); if (rule.AlertFieldId == thisFieldId) break;}The code underneed simulates the same situation in a small job:

static void Job5(Args _args){ anytype any; ; any = ABC::A; // next line will throw a error any = BatchStatus::Canceled;}And here we get the basic same error “Error executing code: Wrong argument types in variable assignment.”

I modified the code so the anytype is assigned only when the field is correct:

while (listChangedFieldsEnumerator.moveNext()){ // In this simple case we use the new and the original changed field value as // recorded at event detection time: thisFieldId = conpeek(listChangedFieldsEnumerator.current(), 1); if (rule.AlertFieldId == thisFieldId) { [thisFieldId, changedFieldValue, origChangedFieldValue] = listChangedFieldsEnumerator.current(); break; }}

Источник: https://www.doens.be/2012/02/ax2009-...cessing-error/
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору.
 

Похожие темы
Тема Автор Раздел Ответов Посл. сообщение
NAV Team: Journal Error Processing Blog bot Dynamics CRM: Blogs 0 20.05.2014 19:46
doens.be: Ax2009 Event Processing Error Blog bot DAX Blogs 0 22.02.2012 10:11
axinthefield: Dynamics AX Event IDs Blog bot DAX Blogs 0 01.03.2011 22:11
wiki.dynamicsbook: Changes Made in Navision Attain 3.60 Blog bot Dynamics CRM: Blogs 0 02.09.2008 13:23
при построении перекрёстных ссылок выдаётся сообщение об ошибках mmmax DAX: Программирование 10 21.01.2005 12:42
Опции темы Поиск в этой теме
Поиск в этой теме:

Расширенный поиск
Опции просмотра

Ваши права в разделе
Вы не можете создавать новые темы
Вы не можете отвечать в темах
Вы не можете прикреплять вложения
Вы не можете редактировать свои сообщения

BB коды Вкл.
Смайлы Вкл.
[IMG] код Вкл.
HTML код Выкл.
Быстрый переход

Рейтинг@Mail.ru
Часовой пояс GMT +3, время: 11:57.
Powered by vBulletin® v3.8.5. Перевод: zCarot
Контактная информация, Реклама.