Skip to main content

Notifications

Announcements

No record found.

Business Central forum
Suggested answer

No overload for method 'AddTranslation' takes 4 arguments. Candidates: 'AddTranslation(Integer, Integer, Text)' defined in Codeunit 'Assisted Setup' by the extension System Application by Microsoft (19.1.31886.32760)

Posted on by 150

Hello all,

Receiving this error message while trying to use the function of the codeunit "Assisted Setup".

AssistedSetup.AddTranslation(myAppInfo.Id, Page::"Customer Rewards Wizard", 1033, WizardTxt);


Any possible hints for this? 

Thanks!

Categories:
  • jimxmy Profile Picture
    jimxmy 150 on at
    RE: No overload for method 'AddTranslation' takes 4 arguments. Candidates: 'AddTranslation(Integer, Integer, Text)' defined in Codeunit 'Assisted Setup' by the extension System Application by Microsoft (19.1.31886.32760)

    Hi!

    So I have two questions regarding this.

    1. Since AssistedSetup is now obsolete, should I be using Guided Experience codeunit instead?

    2. How to find the equivalent method in GuidedExperience, let's say for a method of -

    AssistedSetup.Complete()

    Thanks for your response! Appreciated. 

  • Suggested answer
    Inge M. Bruvik Profile Picture
    Inge M. Bruvik 32,744 Moderator on at
    RE: No overload for method 'AddTranslation' takes 4 arguments. Candidates: 'AddTranslation(Integer, Integer, Text)' defined in Codeunit 'Assisted Setup' by the extension System Application by Microsoft (19.1.31886.32760)

    Here you can see the 3 parameters you should use:

    /// <summary>Adds the translation for the name of the setup.</summary>

       /// <param name="PageID">The ID of the page to open when the user clicks the setup.</param>

       /// <param name="LanguageID">The language ID for which the translation is made.</param>

       /// <param name="TranslatedName">The translated text of the name.</param>

       [Obsolete('Replaced by AddTranslation(GuidedExperienceType, ObjectType, ObjectID, LanguageID, TranslatedName) in the Guided Experience codeunit.', '18.0')]

       procedure AddTranslation(PageID: Integer; LanguageID: Integer; TranslatedName: Text)

       begin

           GuidedExperience.AddTranslationForSetupObjectTitle(GuidedExperienceType::"Assisted Setup", ObjectType::Page, PageID, LanguageID, TranslatedName);

       end;

  • Suggested answer
    Inge M. Bruvik Profile Picture
    Inge M. Bruvik 32,744 Moderator on at
    RE: No overload for method 'AddTranslation' takes 4 arguments. Candidates: 'AddTranslation(Integer, Integer, Text)' defined in Codeunit 'Assisted Setup' by the extension System Application by Microsoft (19.1.31886.32760)

    You have one parameter too much in your function call.

    Are you using the Guided experience codeunit  or the assisted setup codeunit?

    The assisted setup codeunit is marked as obselete.

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

Anton Venter – Community Spotlight

Kudos to our October Community Star of the month!

Announcing Our 2024 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Dynamics 365 Community Newsletter - September 2024

Check out the latest community news

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 290,554 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 228,588 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans