Skip to main content

Notifications

Announcements

No record found.

Small and medium business | Business Central, N...
Suggested answer

Visibility is not working for fields in card page in business central

Posted on by 5

Hi Here the visibility property is not working for field for card page while applying condition. How to fix that issue ??

  • Suggested answer
    YUN ZHU Profile Picture
    YUN ZHU 73,696 Super User 2024 Season 2 on at
    RE: Visibility is not working for fields in card page in business central

    Hi, hope the following helps.

    https://yzhums.com/14752/

    [View:/cfs-file/__key/communityserver-discussions-components-files/758/DynamicVisibility01.mp4:1024:768]

    PS: Deprecating InDataSet attribute used for global variables in Pages (The InDataset attribute is unused)
    https://yzhums.com/37557/

    Thanks.

    ZHU

  • RT-22040800-0 Profile Picture
    RT-22040800-0 5 on at
    RE: Visibility is not working for fields in card page in business central

    Still i am facing the issue.

  • Suggested answer
    Nitin Verma Profile Picture
    Nitin Verma 21,091 Super User 2024 Season 1 on at
    RE: Visibility is not working for fields in card page in business central

    Declare your field like this

    var

           [InDataSet]

           fieldvisible: Boolean;

  • RT-22040800-0 Profile Picture
    RT-22040800-0 5 on at
    RE: Visibility is not working for fields in card page in business central

    first i have created a global variable of FieldVisible and datatype boolean . I had assigned that variable at dependent required field . Then i had written this code.

    modify("Leave Code")

           {

               trigger OnAfterValidate()

               var

                   myInt: Integer;

               begin

                   if Rec."Leave Code" = 'AL' then

                       FieldVisible := true

                   ELSE

                       FieldVisible := false;

               end;

           }

  • Suggested answer
    Nitin Verma Profile Picture
    Nitin Verma 21,091 Super User 2024 Season 1 on at
    RE: Visibility is not working for fields in card page in business central

    Hi,

    You can show your code here.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans