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 :
Finance | Project Operations, Human Resources, ...
Suggested Answer

How to call modify method when barcode is scan on warehouse device?

(0) ShareShare
ReportReport
Posted on by 683

Hi,

I have been working on one requirement which should do some operation when product barcode is scanned, but user is not required to press any button. If they scan a barcode from label it should automatically perform the operation. This I need to do while Purchase order receiving and I know WhsWorkExecuteDisplayLoadItemReceiving class should be used but even after hard try I couldn't get how to call modify method on textbox?

I have the same question (0)
  • Suggested answer
    nmaenpaa Profile Picture
    101,162 Moderator on at

    Your scanner should have a setting that controls whether the scanner sends a line break (enter) after each scan. If it sends a line break, it works exactly like you would type a value with your keyboard and hit enter. This will trigger the modified method.

  • zeeshan.shaikh Profile Picture
    683 on at

    Hi Nikolaos,

    That's fine but where to add this modified method to put my logic?

  • Suggested answer
    zeeshan.shaikh Profile Picture
    683 on at

    Hi Nikolaos,

    I have achieved it by adding below code in createTextBox method of class WhsWorkExecuteForm.

    if(this.elementName(_textBox) == #ItemId)

    {

           stringControl.registerOverrideMethod(methodStr(FormStringControl,modified),methodStr(WHSWorkExecuteForm,DynamicButtonControl_modified),this);

    }

    Which calls my DynamicButtonControl_modified method. Do you have any other better solution?

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 > Finance | Project Operations, Human Resources, AX, GP, SL

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 467 Super User 2025 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 420 Most Valuable Professional

#3
BillurSamdancioglu Profile Picture

BillurSamdancioglu 241 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans