NetTalk Central

Author Topic: Refresh another field after new value in a Lookup field  (Read 2668 times)

hkalmbach

  • Jr. Member
  • **
  • Posts: 80
    • View Profile
    • Email
Refresh another field after new value in a Lookup field
« on: February 05, 2019, 02:11:15 AM »
Hello,

I have a form where the user selects a spare part. This is a lookup field (based on a table, popup). To every spare part the belong one or more stock locations (other table).
In a second field (dropdown) the user can select one of stock locations after selecting a spare part. The dropdown list is based on a queue, which is filled after selecting the spare part.

I fill this queue in the embed point AfterLookup / Fieldname. This works very well if I really use the lookup button behind the field.
But it should also work if I type in a new value for the spare part manually. I have set the option 'Send new value to server' on the tab 'Client-Side' for the spare part field.

I also can debug that the queue for stock locations is really updated after accepting a manually entered value for the spare part.
But I don't succeed in refreshing the drop down field in this case. In my dropdown field there are no values or the values of the spare part before (selected by the button).

Does someone know how to refresh the dropdown list on the screen according the new values in the queue?

Thanks for every help.

Cheers Heinz

By the way: in the lookup settings of my spare part field I have defined a description field (name of spare part), this is not shown on screen. What can be wrong here?


Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11179
    • View Profile
Re: Refresh another field after new value in a Lookup field
« Reply #1 on: February 06, 2019, 10:30:32 PM »
Hi Heinz,

>> The dropdown list is based on a queue, which is filled after selecting the spare part.

It would be better if it was based on a table, with an appropriate filter. Building the queue manually yourself is unnecessary work. The filter would be based on the SessionValue of the Spare Part lookup.

The stock-locations dropdown should be added to the Spare Part field, on the Client-Sdie tab, Reset list.

>> By the way: in the lookup settings of my spare part field I have defined a description field (name of spare part), this is not shown on screen. What can be wrong here?

You need a single-component (preferably unique) key on the description field in the table.


Cheers
Bruce