web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Suggested Answer

Some Item Descriptions are coming and some are not coming.

(0) ShareShare
ReportReport
Posted on by 50

Hi All,

       I am doing a processing only report where it has to show a message, where  if the purchase description is " ", for a item then it has to take from the sales description of my item pageextension but if the purchase description is null also only some items are showing its sales description but some are not showing the sales description, why it is coming like that can anyone help me my code is

Trigger OnafterGetRecord()

begin

clear(Description_Custom);

 if Item.Get("Purchase Line"."No.") then

 if item."Purchase Decription" = '' then

 Description_Custom := Item."Sales Decription"

 else

 Description_Custom := Item."Purchase Decription";

Message('%1,%2',Item.No., Item.Description_Custom);

end;

Below I am attaching the message, if anybody know why it is coming like this help me.

pastedimage1678704250991v1.png

pastedimage1678704330264v2.png

Thanks & Regards

Satish.

  • Suggested answer
    Nitin Verma Profile Picture
    21,812 Moderator on at

    You code seems right to me, where is the problem I did not get you properly.

    Thanks

  • Sarath9999 Profile Picture
    50 on at

    Hi Nitin,

                I am doing a processing only report, I want to show a message of the item No., item Description, in the item table I have given two custom fields, where purchase description and sales description, if the purchase description is blank, it has to take the value from sales description, but for some items it is taking the sales description values for some items and for some items it is showing null, I didn't insert any values in the purchase description.

    Thanks & Regards

    Satish

  • Suggested answer
    Nitin Verma Profile Picture
    21,812 Moderator on at

    Can you try this?

               Trigger OnafterGetRecord()

               begin

                   clear(Description_Custom);

                   if "Purchase Line".type = "Purchase Line".type::Item then begin

                       if Item.Get("Purchase Line"."No.") then

                           if item."Purchase Decription" <> '' then

                               Description_Custom := Item."Purchase Decription";

                           if item."Sales Decription" <> '' then

                               Description_Custom := item."Sales Decription";

                       Message('%1,%2', Item.No., Description_Custom);

                   end;

               end;

  • Sarath9999 Profile Picture
    50 on at

    Hi Nithin,

             I have tried in the way what you said but again also it is not coming, can you have any other suggestions, Thank you very much for your help.

    Thanks & Regards

    Satish.

  • Suggested answer
    Nitin Verma Profile Picture
    21,812 Moderator on at

    Seems that you are not able to describe your requirement, can you please put some screen shot or brief it more

    Thanks

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the August Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 715 Super User 2026 Season 2

#2
YUN ZHU Profile Picture

YUN ZHU 452 Super User 2026 Season 2

#3
AndrewThomas81 Profile Picture

AndrewThomas81 371 Super User 2026 Season 2

Last 30 days Overall leaderboard

Featured topics

Microsoft Training Manuals

Product updates

Dynamics 365 release plans