web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Suggested answer

What is replacing infolog.line when it says obsolete ?

(0) ShareShare
ReportReport
Posted on by 309

Hi,

I'm using "infolog.line" to show my message, but I notice there is a warning while Build saying it is obsolete. It is suggested to use Global class, which one actually and how to use it ? 

The document xGlobal.infologLine Method (Dynamics.AX.Application) | Microsoft Learn is not really clear.

I'm using infolog for my Try Catch() scheme.

for (i=1; i<=infolog.line(); i  )
{
    infolog.text(i);
}

Thanks,

I have the same question (0)
  • Martin Dráb Profile Picture
    236,124 Most Valuable Professional on at
    RE: What is replacing infolog.line when it says obsolete ?

    No, this thread didn't begin with infologLine() (which is the same thing as Global::infologLine()). The question was about infolog.line().

  • Axel Cage Profile Picture
    309 on at
    RE: What is replacing infolog.line when it says obsolete ?

    "The fact that infolog.line() is not related to infolog.text()." This actually quite confusing for some people since at first I thought should be using the same "family" of code, so if now need to use Global class for the infolog.line() then infolog.text() as well, I guess it is not... and no such thing as "family of code"

    Anyway, it is resolved then.

    But for the "simply use infologLine() instead of Global::infologLine()." This is where the thread begin with.

    Thanks

  • Martin Dráb Profile Picture
    236,124 Most Valuable Professional on at
    RE: What is replacing infolog.line when it says obsolete ?

    By the way, the prefix Global:: isn't needed. You can simply use infologLine() instead of Global::infologLine().

  • Martin Dráb Profile Picture
    236,124 Most Valuable Professional on at
    RE: What is replacing infolog.line when it says obsolete ?

    The fact that infolog.line() is not related to infolog.text().

    If you happen to also have a problem with infolog.text(), please create a new thread (because the topic of this one is "What is replacing infolog.line when it says obsolete ?") and explain your problem there.

    It seems that Girish's reply answered your question, so don't forget to to mark it as such (by using Did this answer your question? > Yes).

  • GirishS Profile Picture
    27,825 Moderator on at
    RE: What is replacing infolog.line when it says obsolete ?

    Try the below code.

    for (i=1; i<=Global::infologLine(); i  )
    {
        infolog.text(i);
    }

    Thanks,

    Girish S.

  • Axel Cage Profile Picture
    309 on at
    RE: What is replacing infolog.line when it says obsolete ?

    Hi,

    Yes, but how to show the text then ? for the infolog.text(i), this is the part when it is not clear.

    Thanks

  • Suggested answer
    GirishS Profile Picture
    27,825 Moderator on at
    RE: What is replacing infolog.line when it says obsolete ?

    Hi AxelCage,

    You can navigate to line method of infoLog class by clicking F12. On that class they will recommend you to use another class instead of current one.

    As per the comments mentioned in line method infolog.line() is deprecated and you need to use Global::infologLine();

    Thanks,

    Girish S.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Andrés Arias – Community Spotlight

We are honored to recognize Andrés Arias as our Community Spotlight honoree for…

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
CA Neeraj Kumar Profile Picture

CA Neeraj Kumar 1,140

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 762 Super User 2025 Season 2

#3
Sohaib Cheema Profile Picture

Sohaib Cheema 706 User Group Leader

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans