Вернуться   AXForum > Блоги > Logger
Забыли пароль?
Зарегистрироваться Правила Справка Пользователи Сообщения за день Поиск Все разделы прочитаны

  1. Старый комментарий

    Разное интересное чтобы не забыть

    Issue 3977147 - Resolved
    Role for Invoice Journals in EP
    Product and version: AX 2012 R3
    KB number: 4343204
    Fix type: Application update
    Released Date: 7/10/2018
    In sales Module in EP, while accessing EP with Test User who is having System user, Employee user, Account Receivable Role, Then User is not able to access the Invoice Journal option for Sales Orders in Enterprise Portal.

    Actual Result:

    The changes in the hotfix make sure that User with Role Accounts Receivable Clerk Role will be able to access Invoice journal on EP.
    Запись от Logger размещена 22.09.2020 в 14:46 Logger is offline
  2. Старый комментарий

    Разное интересное чтобы не забыть

    Solution 709488Installation Enterprise Portal
    Product and version: AX 2012 R2
    Partner is unable to install EP as they are receiving an error message "Error: The Website 'http://xxxxxxx/websites/DynamicsAx' wasn't created properly. The Remote server reported an error: (500) Internal Server error"
    The following steps have been taken to resolve the issue:1) Verify if you have SQL rights to the SharePoint config database, if NO assign these rights and then try installing again.2) Empty out the AX business connector proxy account from AX client | System administration | System | System service accounts.3) Delete AXSiteDef folder from C:\Program Files\Common Files\Microsoft shared\Web Server Extensions\14\Template\1033 AND C:\Program Files\Common Files\Microsoft shared\Web Server Extensions\14\Template\SiteTemplates• C:\Program Files\Common Files\Microsoft shared\Web Server Extensions\14\TEMPLATE\LAYOUTS\ep Folder • Delete C:\Program Files\Common Files\Microsoft shared\Web Server Extensions\14\Template\Features\Dynamics* folders • Delete the files starting with Dynamics* from C:\Program Files\Common Files\Microsoft shared\Web server extensions\144) While installing the EP, install it without creating the site. Then check to make sure the above deleted files got re-created including the EP folder that was not there. Then run the EP install again to create the site again.
    Запись от Logger размещена 22.09.2020 в 14:45 Logger is offline
  3. Старый комментарий

    Разное интересное чтобы не забыть

    In Dynamics AX 2012, when you open the forms, you might see some of them open behind the other forms. User may get the impression that the form was never opened. This happens if the form opened slowly; a cold start, uniqueness of the data including large number of records or complexity of the form may cause the form to load up slowly. The form hide behind the other form because of Windows’s ‘ForegroundLockTimeout’.

    Doing the following changes to your system could fix this issue. Since it involves changing a registry key in your system, take necessary precautions.

    Create a Restore point before performing the steps below as a precaution.


    1. Open registry>> Start>>Type regedit>>press enter.

    2. Locate the key:

    HKEY_CURRENT_USER\Control Panel\Desktop

    3. On the right pane right click on the following key and select modify:

    4. ForegroundLockTimeout

    5. Select Base as decimal and then type 0 (zero) in the value data box and click on Ok.

    6. Exit from registry and restart the computer.


    Important This section, method, or task contains steps that tell you how to modify the registry. However, serious problems might occur if you modify the registry incorrectly. Therefore, make sure that you follow these steps carefully. For added protection, back up the registry before you modify it. Then, you can restore the registry if a problem occurs. For more information about how to back up and restore the registry, click the following article number to view the article in the Microsoft Knowledge Base:

    322756 How to back up and restore the registry in Windows
    Запись от Logger размещена 22.09.2020 в 14:44 Logger is offline
  4. Старый комментарий

    Разное интересное чтобы не забыть

    Solution 742836Focus issues with AX client running RemoteApp
    Product and version: AX 2012 R2
    Environment has 2 clustered Windows 2008 R2 Terminal server where the AX client is exposed as Remote App.The Users are accessing the AX client using different OS. (Windows XP SP3, or Windows 7 SP1).The problem they get is that sometimes when form/lookup is opened it goes to background and the user needs to with ALT+TAB search the right form to bring it to the front.
    Within the link below the AX performance team blogged about it for AX 2012 users. The provided solution however (which applied to AX 2009 too) is identical to the one from the blog you found and changing the “ForegroundLockTimeout” registry key. Dynamics AX 2012: Forms on opening hide behind in the back As per the TechNet blogs below the “ForegroundLockTimeout” specifies the time, following user input, during which the system keeps applications from moving into the foreground automatically (without selection by the user). The “ForegroundFlashCount” specifies the number of times the taskbar button flashes to notify the user that the system has activated a background window. If the time elapsed since the last user input exceeds the value of the ForegroundLockTimeout entry, the window will automatically be brought to the foreground. * ForegroundLockTimeout * ForegroundFlashCount Through combining these two keys a clear indication to the user can be realized. The ForegroundFlashCount setting indeed does little more than set the time the picture on the taskbar is flashing once the program/form is started in the background. For windows 2008 and 2008 R2 Remote desktop service (RDS) a number of hotfixes are released (see articles below) specify for “Remote App” there are a number of fixes where windows do not show properly and/or show in the background. * 2312539 Available Updates for Terminal Services (Remote Desktop Services) in Windows Server 2008;EN-US;2312539 * 2699817: * 2696020: steps to check: * Verify the location of the ForegroundLockTimeout and ForegroundFlashCount registry values to be at “HKEY_CURRENT_USER\Control Panel\Desktop” and not in “HKLM:” * Verify the type of values both to be REG_DWORD * Verify the machine has been rebooted to get the values to get effective. * If you have the language bar activated, please switch it off for a Test. * Another thing to check is that, and it happens very often, the Regkey is not set properly. For example what often happen is that they copy and paste it and unfortunately they copy a blank space with it. In this case the complete Regkey didn’t work proper. So maybe exporting the Regkey and check it.
    Запись от Logger размещена 20.09.2020 в 16:07 Logger is offline
  5. Старый комментарий
    Запись от Logger размещена 27.08.2020 в 18:04 Logger is offline
  6. Старый комментарий
    Запись от Logger размещена 14.08.2020 в 13:25 Logger is offline
  7. Старый комментарий
    Запись от Logger размещена 07.02.2020 в 09:49 Logger is offline
  8. Старый комментарий

    Разное интересное чтобы не забыть

    Почему для открытия меню Windows читает один файл сто тысяч раз?
    Запись от Logger размещена 04.02.2020 в 22:28 Logger is offline
  9. Старый комментарий
    Запись от Logger размещена 29.11.2019 в 20:22 Logger is offline
  10. Старый комментарий

    Разное интересное чтобы не забыть

    Установка и базовая настройка SharePoint Server 2013 SP1 на Windows Server 2012 R2 (в топологии Two-tier farm). Часть 2 – Установка SharePoint (Создание фермы)
    Запись от Logger размещена 29.11.2019 в 19:49 Logger is offline
  11. Старый комментарий
    Запись от Logger размещена 29.11.2019 в 19:31 Logger is offline
  12. Старый комментарий
    Запись от Logger размещена 29.11.2019 в 19:26 Logger is offline
  13. Старый комментарий

    Разное интересное чтобы не забыть

    64bit machine – VS EP add-in not deploying user control to SharePoint while saving

    In 32 bit machine, when you edit an user control in VS using EP add-it, it automatically uploads the saved file to both AOT and to SharePoint (“%SYSTEM Drive:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\TEMPLATE\LAYOUTS\ep" folder on the web server)

    If you are using 64 bit machine for EP, make sure getSharepointTemplatePath method of SysEPDeployment class in AOT has the below code . This is needed so that whenever you save user controls in VS, that will automatically be deployed to the EP server same as in 32 bit env.

    public static str getSharepointTemplatePath()
    str templatePath ='';
    templatePath =SysEPDeployment::getSharepointTemplatePathDotNet();
    return templatePath? templatePath:SysEPDeployment::getSharepointTemplatePathWin32();

    Thanks to John Hermsen from Giant Bicycles for providing a similar workaround.

    (2) If you are making change to user controls in Visual studio, then there are no additional steps to have these changes propagated to the EP Server. Whenever you make changes on already existing user control in VS, it will automatically copy it to the SharePoint folder location. If you are creating new user control, when you add it to AOT by the right click menu and save the control in VS, it will automatically copy it to the SharePoint location.

    (3) If you are making changes to Tables/EDTs/Enums/Data Sets/Classes, then you need to click the “Refresh AOD” link available to the administrators in the EP home site quick launch. This will clear the metadata cache. You can also do an “iisreset” if needed

    If you are making change to proxy file/static files/resources, then you need to deploy them. User AxUpdatePortal utility (Manage Deployment Option does not work in 64 bit machines,so you have to use AXUpdatePortal)

    Tags Deployment
    Comments (6)
    January 15, 2010 at 1:41 am
    Hi Mey,

    We are working on EP & SSRS. We are not able to find the right way of passing parametrs from EP to SSRS reports ie: generate a report based upon the current record selected in an AXGrid control.

    Please provide some solution.

    March 5, 2010 at 11:36 pm
    could be the ability to specify report parameters through the URL.

    This can be done by using the parameter selector in the report webpart and appending the URL with “<parameterSelector>.ParamName=value”

    IT Outsourcing
    March 28, 2010 at 10:58 pm
    Hey that’s very good point but I am a bit confused on the 2nd point that is making change to user controls in Visual studio, then there are no additional steps to have these changes propagated to the EP Server. Is it really?

    June 21, 2010 at 3:01 am
    @ player

    Thanks for the comment.

    Can you please elaborate a bit more ? How we are going to do it programatically.

    Like with X++/ classic client we can use menufunction and pass parameters directly to SSRS reports, how we can achieve the same with EP?

    June 21, 2010 at 3:01 am
    @ player

    Thanks for the comment.

    Can you please elaborate a bit more ? How we are going to do it programatically.

    Like with X++/ classic client we can use menufunction and pass parameters directly to SSRS reports, how we can achieve the same with EP?

    Another point how we will achive this in a multi param scenario…

    October 24, 2010 at 5:36 am
    This is an excellent article, thank you very much for it, I have found here much useful information in
    Запись от Logger размещена 29.11.2019 в 19:22 Logger is offline
  14. Старый комментарий
    Запись от Logger размещена 03.09.2019 в 14:53 Logger is offline
  15. Старый комментарий
    Запись от Logger размещена 09.06.2019 в 23:32 Logger is offline
  16. Старый комментарий

    X++, the catch Michael Fruergaard Pontoppidan November 24, 2016

    Velislav M
    November 29, 2016 at 9:03 am
    Not a fan of compiler magic, but this is an example of how syntax sugar makes us fat and lazy. Can we have some more, please!
    We already know what the correct “catch-all” block should look like…
    So, why can’t we have a keyword that automatically emits all the boilerplate code for handling correctly the update-conflict and duplicate-key exceptions?

    I mean, going forwrad, it would be nice if we could write code that can be fully covered by unit tests without too much hassle.
    And creating a macro, or a separate class, for just handling transaction exceptions is simply not as good.
    Sometimes, more control will be needed, but most of the time people will be just fine with a “smart default”

    Log in to Reply
    November 25, 2016 at 3:33 pm
    Michael, I believe that it is necessary to fix the core.

    Correction in X ++ code has a number of problems:
    1. Not all developers know about the bug discussed and probably will never know. (Moreover, few people know ). It is therefore not correct to be a bug. The bug will remain forever. For example, I posted information about it on axforum in 2011, but so far very few people know about it in Russia. (axforum – the only Russian-language resource on DAX)
    2. Most of the developers since Ax3, accustomed that the transaction is atomic and X ++ supports it (Acid). But this is not the case.
    3. Documentation X ++ explicitly recommends that you can use Exception- All. It is not enough to recommend the developers to correct the X ++ code. At the same time it is necessary to fix the system documentation.
    4. In reality, now the developer is forced to constantly think about the danger and cumbersome to write exception handling. This is extremely inconvenient and prevents focus on the essentials. X ++ in this case, – makes life difficult, not easier.
    5. Find all the places in the code that must be very difficult to correct. (They are still many standard code)

    In the case of kernel patches:
    1. Developers do not need to be aware of this bug and a lot of problems with uninformed programmers disappears.
    2. Acid still been supporting X ++. Software really gets what he expects and what it was used since ax3
    3. It is not necessary to correct the documentation – the system will start to work as well as recommended in the documentation.
    4. Exception handling code is again very simple. There is no need to think about the complex. (This is the main reason. Most developers will simply be happy by this simplification.)
    5. Do not look for a lot of places in the code X ++ to fix. It is enough to put a fix for the kernel! I think you will agree that it is much easier than to review and analyze all of the source X ++ code. In addition, a bug often works, But users and programmers do not notice it. For them, the situation looks like in the middle of a transaction to commit. Now all is corrected itself.

    And further:
    I do not know the kernel source code, but I think that to correct the mistake would not be very difficult as the kernel, when exiting ttsBegin/ttsCommit scope – changes ttslevel, ie kernel monitors the level of the transaction. I think that we should not reduce the tts-counter by 1, but the transaction counter is to be reseted to 0. It will be safer. (In this case, we do not renounce the TTSunrollbackable exceptions. Only fix their behavior)

    Log in to Reply
    Metin Emre
    November 28, 2016 at 4:57 pm

    I think this’s not a bug. first record saved, while second is saving there’s an error occurs and you decided what’ll do in catch. You can ignore the bug, or you can throw an error and break the transcaction. That’s logical. However I never noticed this behaviour until today and in first a bit shocked.

    Thanks for article…

    Log in to Reply
    November 25, 2016 at 8:41 am
    thanks for post.
    It’s stupid core bug, as i see.
    That ‘trick’ don’t happens in old version of AX. I check it on AX4, and when raise UpdateConflict on the line of credit update, code goes to catch in postList method. And therefore, without any violation of transactional integrity.

    Log in to Reply
    Michael Fruergaard Pontoppidan
    November 25, 2016 at 9:09 am
    Thanks! That is very useful information. I’ve tried this in AX2012 R3 and AX7. Both have this problem. Does anyone have an AX2009 they can try on?

    Log in to Reply
    November 25, 2016 at 12:49 pm
    I’ve tried in ax2009.
    Bug exists and caused some problem in production.

    I described this here
    Развалились InventSum - InventTrans

    Here is brief translation
    The job :
    static void Job791_15(Args _args)
    #define.recIdTrans(5637151827) // here must be existsing recid from InventTrans.
    InventTrans InventTrans;
    InventSum InventSum;
    InventTrans = InventTrans::findRecId(#recIdTrans, true);
    InventTrans.Qty += 1.0;
    info(“Catched inner catch”);
    info(“Catched outer catch”);

    info(strFMT(“InventTrans.RowCount() = %1, InventTrans.Qty = %2, InventSum : %3 “,
    con2str(Global::buf2Con(InventSum::find(InventTrans.ItemId, InventTrans.inventDimId)), “; “)


    How to use:
    1. Edit job, setting in line 3 the recid of existing InventTrans.
    2. Open 2 ax client.
    3. Run the job on the first client and wait when it stops in debugger.
    4. Run the job on the second client and wait. Client must hang. It wil be blocked by first client.
    5. Press F5 in debugger for first client.
    6. Press F5 in debugger for second client.
    So, both jobs are to be performed.
    As result, InventTrans.Qty increases by 1.0 and the apropriate column in InventSum increases by 2.0

    November 25, 2016 at 1:10 pm
    It can not be reproduced in ax3 because it does not support Exception::UpdateConflict and Exception:uplicateKeyException

    Michael Fruergaard Pontoppidan
    November 26, 2016 at 7:41 am
    Hi AGolubkov,
    What is the build number of AX4 you tried on? I looked at the compiler/interpreter code in AX4 vs AX2009 and found nothing indicating the behavior should be different.

    UPDATE: I tried on AX4SP1, it also has this problem. I’m going to assume this has been an issue since the new exception types got introduced.
    There is an image showing it here:


    Log in to Reply
    February 2, 2017 at 8:33 am
    Hi Michael,
    sorry for late reply, I didn’t see your question.

    I’ve tried it on application Dynamics AX 4.0 SP2 4.0.2501.116, and hadn’t any problems with trasactional integrity in this example.

    February 2, 2017 at 8:38 am
    Hi Michael,
    soryy for late reply, I didn’t see your question…

    I’ve tried this example in DAX application Dynamics AX 4.0 SP2 4.0.2501.116.
    And I didn’t see any problem with transactional integrity.

    November 24, 2016 at 5:47 pm
    Nice post. Do you have any ideas how to find such ‘unsafe’ code in the existing application

    Log in to Reply
    Michael Fruergaard Pontoppidan
    November 24, 2016 at 7:12 pm
    Hi Denis, there are many ways to find them. As I had all source files on disk (I’m on the AX7 stack), I did a “findstr /i /s /C:”catch” *.* >catches.txt”. Then I used Notepad++ to filter out the noise. Within a few minutes I had the list of potential problems, and I then started the investigation in Visual Studio. There are other (and likely more efficient) ways – but this did the job for me.


    Log in to Reply
    November 25, 2016 at 4:19 am
    By the way – can you register this issue as a bug?
    It seems more logical that the language should guarantee that what is written between ttsbegin.. ttscommit should be considered as one transaction, not just the way that developer write code

    Michael Fruergaard Pontoppidan
    November 25, 2016 at 9:13 am
    Let us assume this is a compiler bug, and it get resolved as a KB. How long will it take before all systems in the world are patched? Wouldn’t it be better to write code that is reliable with and without the fix. Another complicating factor is that all X++ must be recompiled for an eventual fix to have any effect. Rest assured the X++ compiler team is informed; and this thread will be updated with news.

    November 29, 2016 at 1:36 pm
    Hi Michael.

    >> Never use catch “all” without explicitly catching updateConflict and duplicateKey exceptions.

    I suggest to create a BestPractice check, verifying before the code “Catch-ALL” is always exists “catch (Exception::UpdateConflict)” and “catch (Exception:uplicateKeyException)”

    What we get:
    1. There will be found all the places that need to be fixed, with the global compilation.
    2. If one uses Exception incorrectly, BP check warns programmer. So, code will be fixed immediatly.
    3. In the future, it will be easier to maintain the correct code.

    Martin Dráb
    November 24, 2016 at 3:55 pm
    A nice demonstration of an ugly problem.

    It also shows that X++ / AX lacks tools for developers to handle exceptions correctly – catch clauses in “What does reliable code look like?” take more than 30 lines. Also, X++ doesn’t have a statement for re-throwing the same exception (as throw; does in C#).

    There are also other issues with exception handling. If anybody can break my exception handling logic just by calling my method from inside a transaction, it means that I can’t really rely on it. Together with the fact that exceptions don’t carry additional details such as a type (something like FileNotFoundException) it leads to a complete absence of code for recovering from errors (people either let the process stop, or handle all exceptions, as in this post).

    Generics and better exceptions are my top two things I would like to see in X++.

    Log in to Reply
    Michael Fruergaard Pontoppidan
    November 24, 2016 at 7:23 pm
    Hi Martin, As this post points out, it is actually possible to handle exceptions in X++ correctly, and it is possible to write a method that cannot be broken by a consumer. My hope is that this post will enable X++ developers to do so.

    I do agree that handling of exceptions is much too hard and much too verbose in X++; and there is plenty of room for improvements.


    Log in to Reply
    November 25, 2016 at 11:19 pm
    So it is a bug in the core which is at least 5 years old and we have a solution now: “Just avoid holding it in that way”. Cheers

    Martin Dráb
    November 27, 2016 at 2:57 am
    Micheal, I mean that if I want, for example, all errors to be logged and then continue processing (or use any other arbitrary error handling logic), all my logic is ignored when somebody calls my logic from inside of another transaction.
    Your post doesn’t show how to address it and it can’t, because it’s not possible. Your post is clearly about exceptions that don’t have this problem, because they actually *can* be handled inside transactions.

    Michael Fruergaard Pontoppidan
    November 28, 2016 at 7:57 am
    Thanks for the elaboration, Martin. The original design of transaction and exception handling in AX was to ensure data integrity – at the cost of flexibility. Giving back the full flexibility as you are requesting without risking data integrity is an interesting challenge. (As this post shows).
    Запись от Logger размещена 03.06.2019 в 09:43 Logger is offline
  17. Старый комментарий

    Разное интересное чтобы не забыть

    Как пишут расширения для редактора.
    Пошаговая инструкция
    Запись от Logger размещена 14.05.2019 в 14:39 Logger is offline
  18. Старый комментарий
    Запись от Logger размещена 08.11.2018 в 10:30 Logger is offline
    Обновил(-а) Logger 08.11.2018 в 10:39
  19. Старый комментарий

    Разное интересное чтобы не забыть

    AX2012 Upgrades – Setting a clean AX2012 database to start with the upgrade check-list and not the Initialization check-list.

    As some of you who work on AX 2012 Upgrades may already know, you need to select the AOS along with the Database option in the AX setup to get the “Register this database for Upgrade” option.

    However, if you already have an AOS service installed and want to setup a new database for an upgrade, sometimes you don’t want to install another AOS just to do get this option. If this is the case, you can run the following script as a workaround to modify the database after the install, so that the upgrade checklist is shown when you start the client:







    DELETE FROM SysSetupLog

    WHERE NAME = ‘SysCheckList_Setup’

    OR NAME LIKE ‘SysCheckList_Up%’

    The statement creates the required stored procedure for the SysCheckList classes to identify this is an upgrade database, and in case you have already started the initialization check-list, it also removes any previous records from SysSetupLog.

    As with any direct updates to the database, it is recommended that you make a backup so you can restore the database if required. Also, only use this on a newly installed database!

    Maxim Gorbunov
    If upgrading from 4.0 or 2009 to AX 2012 R2, you also have to switch to table-per-type table inheritance mode (see Data Upgrade Best Practices (White Paper) for details, To do so, you have to create one more stored procedure in addition to that mentioned above:



    Is there any way to do it the other way around? I have checked the option "register the database for upgrade" during setup but I do not want to run any of the upgrade checklists so I want to remove the "register the database for upgrade" option. Is that possible or do I have to reinstall the database and AOS?

    5 years ago
    Hi Johan,

    You could try dropping the Stored Procedure "[dbo].[SETUPVERSIONPROC]". This is only created when you select the option "register the database for upgrade". If this is not present it will assume that this is a fresh install and not for an upgrade. You may also need to run the DELETE statement above on the SysSetupLog table. I've not tested this, but from what I found when looking at this in the past, I believe it should work.

    Thanks, Thomas
    Запись от Logger размещена 21.09.2018 в 17:57 Logger is offline
  20. Старый комментарий
    Запись от Logger размещена 25.04.2018 в 10:14 Logger is offline

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