Skip to main content

Notifications

Finance | Project Operations, Human Resources, ...
Answered

Error: MyWizard class does not have a clicked method.

(0) ShareShare
ReportReport
Posted on by 100

Hi, I am creating my own wizard by extending sysWizard class. 
In addition, there is a new FormFunctionButtonControl 'wfButton' and register override method for clicked action in the same class but still I am getting error: MyWizard class does not have a clicked method although it is there. However, I also did a full build but still nothing good happens.

wfButton.registerOverrideMethod(methodStr(FormFunctionButtonControl, clicked), methodstr(MyWizard, clicked), this);

public void clicked()
{
       Info('wfButton clicked');
}


Looking forward to your suggestions.

  • Martin Dráb Profile Picture
    Martin Dráb 230,853 Most Valuable Professional on at
    RE: Error: MyWizard class does not have a clicked method.

    Well, it's mainly about experience. I know how registerOverrideMethod() works.

    Also, it makes sense. You often need a reference to the form control, e.g. to get the current value. You can't refer to "this" as if you overrode a method of the control itself, because your method is in a different class. The only way is using a parameter.

  • D356FO_Dev Profile Picture
    D356FO_Dev 100 on at
    RE: Error: MyWizard class does not have a clicked method.

    Thank you so much it works.

    How did you know that as I could not find this in Microsoft documentation.

  • Verified answer
    Martin Dráb Profile Picture
    Martin Dráb 230,853 Most Valuable Professional on at
    RE: Error: MyWizard class does not have a clicked method.

    The problem is that your clicked() method doesn't have the right parameters. It should have a parameter accept an instance of the button.

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

Announcing Our 2025 Season 1 Super Users!

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

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Congratulations to the January Top 10 leaders!

Check out the January community rock stars...

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,996 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 230,853 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans