Skip to main content

Notifications

Announcements

No record found.

Business Central forum
Answered

captions change issue

Posted on by 175

hi,

I am trying to change the captions of all field in customer card and it;s successfully changed but some of the fields cation are not changed like 

Total sales, Cost($), Profit($).

Can any one help me and tell me why these fields cations are not chaging ?

Categories:
  • Suggested answer
    Olister Rumao Profile Picture
    Olister Rumao 3,957 on at
    RE: captions change issue

    See,

    Create a group and move all fields from General to that group.

    Give captions to that group.

    And hide General group.

  • SirDard Profile Picture
    SirDard 175 on at
    RE: captions change issue

    Thanks olister,

    It's working . can you tell me how can i change group caption like I need to change

    group(General) caption because its not changed through modify(general) command.

  • Verified answer
    THE Italian Profile Picture
    THE Italian on at
    RE: captions change issue

    Yup. For these calculated values and the one under the Caption Class you have to create a facade field with the caption you like and make the standard field not visible.

  • Verified answer
    Olister Rumao Profile Picture
    Olister Rumao 3,957 on at
    RE: captions change issue

    Hi Waqar Ahemad,

    AFAIK you cannot change the Captions of the fields which already have a CaptionClass.

    Add a new field in the page with source as variable and add you caption as needed.

    And then modify the

    addafter(TotalSales2)

    {

    field(TotalSales2_NEW;GetTotalSales)

    {

        ApplicationArea= All;

        Caption= 'Your Caption'

    }

    }

    modify(TotalSales2)

    {

      Visible = false;

    }

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: captions change issue

    for the code sample see the reply from Duilio Tacconi

  • SirDard Profile Picture
    SirDard 175 on at
    RE: captions change issue

    Hi, Aotto

    Thanks for your quick response .

    One thing can you please give me any example what you actually want to say like we have a field name Total sales in sales invoice we are unable to change its caption so how we can add new field for this with the same source ?

    Another also we have noticed there are multiples of fields which donot change its caption so we have to use your idea for all fields like Address, city , Contact in sales Invoice ?

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: captions change issue

    You cannot change existing field caption in Page Extension object.  What you need to do is to hide the field  and add new field with the same "Source" then you can change the caption

    See below link for what you can or can't do in Page Extension.

    docs.microsoft.com/.../devenv-page-property-overview

  • SirDard Profile Picture
    SirDard 175 on at
    RE: captions change issue

    Hi, Duilio,

    Thanks for your quick response.

    I am trying with below code.

    pageextension 50008 SalesInvoice_Extension extends "Customer Card"

    {

       layout

       {

           // Add changes to page layout here

           modify(TotalSales2)

           {

               ApplicationArea = Basic, Suite;

               Caption = 'Total';

               Importance = Additional;

               ToolTip = 'Specifies the number of the contact the invoice will be sent to.';

               //CaptionClass = Format(StrSubstNo(OverduePaymentsMsg, Format(WorkDate)));

           }

    also i was trying with XLIFF  file but no luck.

    yes, its global variable but how to change its caption ? can you help me ?

  • Suggested answer
    THE Italian Profile Picture
    THE Italian on at
    RE: captions change issue

    What kind of changes you did? Have you implemented an appropriate XLIFF file or?...

    What you mention are NOT fields, these are global variables calculated within the pages. See below W1 version

    ...

                   field(TotalSales2; GetTotalSales)

                   {

                       ApplicationArea = Basic, Suite;

                       Caption = 'Total Sales';

                       Style = Strong;

                       StyleExpr = TRUE;

                       ToolTip = 'Specifies your total sales turnover with the customer in the current fiscal year. It is calculated from amounts excluding VAT on all completed and open invoices and credit memos.';

                   }

                   field("CustSalesLCY - CustProfit - AdjmtCostLCY"; CustSalesLCY - CustProfit - AdjmtCostLCY)

                   {

                       ApplicationArea = Basic, Suite;

                       AutoFormatType = 1;

                       Caption = 'Costs (LCY)';

                       ToolTip = 'Specifies how much cost you have incurred from the customer in the current fiscal year.';

                   }

                   field(AdjCustProfit; AdjCustProfit)

                   {

                       ApplicationArea = Basic, Suite;

                       AutoFormatType = 1;

                       Caption = 'Profit (LCY)';

                       Editable = false;

                       Importance = Additional;

                       ToolTip = 'Specifies how much profit you have made from the customer in the current fiscal year.';

                   }

                   field(AdjProfitPct; AdjProfitPct)

                   {

                       ApplicationArea = Basic, Suite;

                       Caption = 'Profit %';

                       DecimalPlaces = 1 : 1;

                       Editable = false;

                       Importance = Additional;

                       ToolTip = 'Specifies how much profit you have made from the customer in the current fiscal year, expressed as a percentage of the customer''s total sales.';

                   }

    ...

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