static void FAN_GLImport(Args _args)
{
AxLedgerJournalTable header = new AxLedgerJournalTable();
AxLedgerJournalTrans trans = new AxLedgerJournalTrans();
container ledgerDim, offsetDim;
LedgerJournalNameId ledgerJournalNameId = "GeneralJR";
DimensionAttributeValueCombination ledgerDimension;
LedgerJournalACType accType, offsetAccType;
BankAccountTable bankAccountTable; ;
accType = LedgerJournalACType::Ledger;
offsetAccType = LedgerJournalACType::Bank; header.parmJournalName(ledgerJournalNameId);
header.save(); trans.parmAccountType(accType);
trans.parmJournalNum(header.ledgerJournalTable().JournalNum); //If account type is Ledger
ledgerDim = ["142102-C-ADMIN","","C","ADMIN"];//First is Display value, followed by Main Account and then dimensions. //If account type is other than ledger then Switch case statement can be written to get RecId from DimensionAttributeValueCombination Table. trans.parmLedgerDimension(AxdDimensionUtil::getLedgerAccountId(ledgerDim));
trans.parmAmountCurDebit();
trans.parmOffsetAccountType(offsetAccType); switch(offsetAccType)
{
case LedgerJournalACType::Bank : select firstOnly bankAccountTable
join RecId from ledgerDimension
where ledgerDimension.DisplayValue == bankAccountTable.AccountID
&& bankAccountTable.AccountID == "ICICI Bank";
trans.parmOffsetLedgerDimension(ledgerDimension.RecId); //Same cases has to be written for others like Vendor, Customer. Except Account type ledger
//If offset account type is ledger then trans.parmOffsetLedgerDimension() will only be supported.
} //trans.parmOffsetLedgerDimension(AxdDimensionUtil::getLedgerAccountId(offsetDim));
trans.save(); }

How to using x++ code create GL journal[AX2012]的更多相关文章

  1. How to using to code import to GL journal[AX2012]

    static void THK_importLedgerJournalTrans(Args _args) { Filename fileName = "C:\\Users\\ksiu3880 ...

  2. Visual Studio Code create the aps.net core project(Visual Studio Code 创建asp.net core项目)

    Install the C# plug-in as shown below: Perfom the dotnet new --help command as shown below: Enter a ...

  3. Oracle Applications Multiple Organizations Access Control for Custom Code

    档 ID 420787.1 White Paper Oracle Applications Multiple Organizations Access Control for Custom Code ...

  4. How to: Synchronize Files by Using Managed Code

    The examples in this topic focus on the following Sync Framework types: FileSyncProvider FileSyncOpt ...

  5. 转载:Character data is represented incorrectly when the code page of the client computer differs from the code page of the database in SQL Server 2005

    https://support.microsoft.com/en-us/kb/904803 Character data is represented incorrectly when the cod ...

  6. URAL 1780 G - Gray Code 找规律

    G - Gray CodeTime Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://acm.hust.edu.cn/vjudge/contest/view ...

  7. 002.Create a web API with ASP.NET Core MVC and Visual Studio for Windows -- 【在windows上用vs与asp.net core mvc 创建一个 web api 程序】

    Create a web API with ASP.NET Core MVC and Visual Studio for Windows 在windows上用vs与asp.net core mvc 创 ...

  8. Object Detection with 10 lines of code - Image AI

    To perform object detection using ImageAI, all you need to do is Install Python on your computer sys ...

  9. WPS 2019 How To Create New Sheets For Each Row In Excel?

    https://www.extendoffice.com/documents/excel/3197-excel-create-new-sheet-for-each-row.html  How To C ...

随机推荐

  1. 03-position和anchorPoint

    *:first-child { margin-top: 0 !important; } body > *:last-child { margin-bottom: 0 !important; } ...

  2. 《Code Complete》ch.24 重构

    WHAT? 重构(refactoring),Martin Fowler将其定义为“在不改变软件外部行为的前提下,对其内部结构进行改变,使之更容易理解并便于修改”. WHY? 神话:一个管理很完善的软件 ...

  3. pytest学习笔记(二)

    继续文档的第二章 (一)pytest中可以在命令行中静态/动态添加option,这里没什么好讲的,略过... 这里面主要讲下如何试用skip/xfail,还有incremental(包含一些列的测试步 ...

  4. 哪项技术可以用在WEB开发中实现会话跟踪实现?

    HTTP是“无状态”协议:客户程序每次读取 Web 页面,都打开到 Web 服务器的单独的连接,并且,服务器也不自动维护客户的上下文信息.即使那些支持持续性 HTTP 连接的服务器,尽管多个客户请求连 ...

  5. The BKS System for the Philco-2000 学习笔记

    最近因为学业需要阅读这一篇论文......一把鼻涕一把泪地翻了一边以求更好地理解,谁让我英语渣呢....有很多地方翻译得感觉还是有问题或者不流畅,还请大家多多指教. The BKS System fo ...

  6. rabbitmq学习笔记

    1 基本概念 rabbitmq server(broker server):rabbitmq服务 client:包括producers和consumer message:包括payload和label ...

  7. 解决visual studio已安装的问题

    使用Windows Install Clean Up(用管理员身份打开),找到相应的软件

  8. 使用Cookie保存商品浏览记录

    数据流程:页面上是商品列表,点击<a href="productServlet">商品名</a> ==>跳转到自定义的servlet中进行处理,先得到 ...

  9. .NET本质论之三(应用程序对象 )

    2.1 请求的处理参数------上下文对象HttpContext   现在,请求已经到达了ASP.NET服务器,为了处理请求,ASP.NET在服务器上创建了HttpRequest类型的对象以表示请求 ...

  10. CSS强制文本在一行内显示若有多余字符则使用省略号表示

    这篇文章主要介绍了强制文本在一行内显示,多余字符使用省略号,设置或检索是否使用一个省略标记(...)标示对象内文本的溢出.对应的脚本特性为textOverflow 设置或检索是否使用一个省略标记(.. ...