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

Notifications

Announcements

No record found.

Community site session details

Community site session details

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

How to edit blob field in Navision

(0) ShareShare
ReportReport
Posted on by 231

Hi,

   I added six blob fields in setup screen, for all fields can we use get and set process. i tried for single field is there any option to write a code for all field in a single function.

Thanks in Advance.

I have the same question (0)
  • Suggested answer
    Inge M. Bruvik Profile Picture
    1,111 Moderator on at

    That depends what is the source of the data you want to put in the fields.

    Are you you important data from files or do you have other sources for your data?

  • Suggested answer
    YUN ZHU Profile Picture
    95,593 Super User 2025 Season 2 on at

    Hi, if this is a customization, you can add some code (function) to the OnValidate (Fields) Trigger to synchronize the other five values when one is entered.
    More details: https://learn.microsoft.com/en-us/dynamics-nav/onvalidate--fields--trigger

    Hope this helps.

    Thanks.

    ZHU

  • yoheswaran Profile Picture
    231 on at

    Is there any way to enter text in blob field on navision i tried with SetDescription and WorkDescription it's not working.

    Thanks

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

    Hi you can try this code

       procedure SetWorkDescription(NewWorkDescription: Text)

       var

           OutStream: OutStream;

       begin

           Clear("Work Description");

           "Work Description".CreateOutStream(OutStream, TEXTENCODING::UTF8);

           OutStream.WriteText(NewWorkDescription);

           Modify();

       end;

    procedure GetWorkDescription() WorkDescription: Text

       var

           TypeHelper: Codeunit "Type Helper";

           InStream: InStream;

       begin

           CalcFields("Work Description");

           "Work Description".CreateInStream(InStream, TEXTENCODING::UTF8);

           exit(TypeHelper.TryReadAsTextWithSepAndFieldErrMsg(InStream, TypeHelper.LFSeparator(), FieldName("Work Description")));

       end;

  • yoheswaran Profile Picture
    231 on at

    Thanks for the reply "TryReadAsTextWithSepAndFieldErrMsg" this function is not available in Type Helper codeunit in navision 2017

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

    I have shared the code for an idea, how you can implement in your version.

    you can follow that link

    learn.microsoft.com/.../how-to--use-streams-to-write-to-text-files

    learn.microsoft.com/.../how-to--use-streams-to-read-from-text-files

  • Suggested answer
    YUN ZHU Profile Picture
    95,593 Super User 2025 Season 2 on at

    Hi, you can refer to the practice of Work Description.

    pastedimage1680737805885v1.png

    And hope the following can give you some hints.

    https://andreilungu.com/read-write-text-from-to-blob-fields-generic-way-nav/

    Thanks.

    ZHU

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

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

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 3,010

#2
Jainam M. Kothari Profile Picture

Jainam M. Kothari 1,270 Super User 2025 Season 2

#3
YUN ZHU Profile Picture

YUN ZHU 1,085 Super User 2025 Season 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans