Skip to main content

Notifications

Announcements

No record found.

Business Central forum
Unanswered

Add New Action to Page Extension When Existing Page Currently Has No Actions

Posted on by

I am looking to add an action to an existing page that currently does not contain any actions.

Since there are no actions on the page, AddAfter(), AddBefore(), AddFirst(), & AddLast() do not work because there is nothing to 'Anchor' to.

    actions
    {
         AddLast(Anchor)
            {
                rAction
             }
    }
I had read somewhere that you can use something like AddLast(Creation) - and Creation would be an anchor when you need to create your first action, but it doesn't work. Visual Studio lists it as an error.
How do you add add a new action on a page without actions?
This is for a BC14 installation and will be used in many localizations (DE,UK, ES, Ect). I beleive the runtime version is 3.2, or something like that.
Thanks!
Categories:
  • CT-29050345-0 Profile Picture
    CT-29050345-0 4 on at
    Add New Action to Page Extension When Existing Page Currently Has No Actions
    pageextension id "Vendor Bank Account Card Ext" extends "Vendor Bank Account Card"
    {
        actions
        {
            addlast(Processing)
            {
                action("New Action")
                {
                    Caption = 'My New Action';
                    ApplicationArea = All;
                    Image = Action;

                    trigger OnAction()
                    begin
                        Message('This is my new action!');
                    end;
                }
            }
        }
    }


    In Visual Studio Code, I click Ctrl + Space and it give me the answer for this question.
  • VokesoJcl Profile Picture
    VokesoJcl on at
    RE: Add New Action to Page Extension When Existing Page Currently Has No Actions

    Page 9042 - Team Member Activities.  - althought the question is for any page that doesn't have existing actions. I don't know how to provide an 'Anchor' when there isn't anything already there.

    Thank You.

  • Inge M. Bruvik Profile Picture
    Inge M. Bruvik 32,720 Super User on at
    RE: Add New Action to Page Extension When Existing Page Currently Has No Actions

    What page (object no.) are you trying to add an action to?

Helpful resources

Quick Links

Replay now available! Dynamics 365 Community Call (CRM Edition)

Catch up on the first D365 Community Call held on 7/10

Community Spotlight of the Month

Kudos to Saurav Dhyani!

Congratulations to the June Top 10 community leaders!

These stars go above and beyond . . .

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 287,989 Super User

#2
Martin Dráb Profile Picture

Martin Dráb 225,588 Super User

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans