axapta - Setting Vendor Number in X++ General Journal -


i'm posting general journal in ax 2012. i'm able create journal , enter line information x++ code. i'm having issue vendor numbers.

when use code of time works. there few vendor numbers not able found table , of course throws error. weird thing if go ax , type in vendor number accept because has been setup in system code not working (for some).

just wondering if there wrong how vendor number setup, not linked something, or if there way set parameter.

it looks parmledgerdimension uses recid vendors , pulls dimensionattributevaluecombination.

any ideas?

dimensionattributevaluecombination  davc; firstonly recid davc davc.displayvalue == account; //could 010-000001 journaltrans.parmledgerdimension(davc.recid); 

try using

dimensionstorage::getdynamicaccount(account, ledgerjournalactype::vend); 

https://msdn.microsoft.com/en-us/library/dimensionstorage.getdynamicaccount.aspx

edit: first line posted default dimension. i'll leave in case need it

ledgerjournalengine::getaccountdefaultdimension(account, curext(), ledgerjournalactype::vend); 

https://msdn.microsoft.com/en-us/library/ledgerjournalengine.getaccountdefaultdimension.aspx


Comments

Popular posts from this blog

1111. appearing after print sequence - php -

java - WARN : org.springframework.web.servlet.PageNotFound - No mapping found for HTTP request with URI [/board/] in DispatcherServlet with name 'appServlet' -

Ruby on Rails, ActiveRecord, Postgres, UTF-8 and ASCII-8BIT encodings -