NetTalk Central

Author Topic: Getting the productID as well as the description when using a lookup  (Read 2884 times)

terryd

  • Hero Member
  • *****
  • Posts: 759
    • View Profile
    • Davcomm
    • Email
I am calling a lookup on a table Product to assign a value to   APP:ProductID. I have the 'DisplayDescription instead of value 'checked.
The value assigned to  APP:ProductID is the description rather than the value after the lookup.
I understand this and I assume that when the record is written away the ID value is substituted for the Description which is why the Description in the Product table has to be unique .
This however causes a problem in a calculation taking place after the APP form is reloaded since it uses a CASE OF based on the productID as a Long, rather than a string
I have to use the lookup because I need to populate some other fields from the product table so AFAIK a drop will not  not work.
I would like to use 'DisplayDescription instead of value ' since it looks better on the screen
Is there a way to get the productID value via the template?
I tried created a local variable and using the  more assignments list to get the productID but I don;t seem to get a value back.
Terry Davidson
Windows 10 64 bit/Windows7 64bit
Clarion 9.1.11529/Clarion10 12567
Nettalk 913
Nettalk 1015
StringTheory267/Winevent515/XFiles298/MessageBox239/Cryptonite186

bruce2

  • Full Member
  • ***
  • Posts: 108
    • View Profile
    • Email
Re: Getting the productID as well as the description when using a lookup
« Reply #1 on: February 02, 2012, 11:52:59 AM »
In the AfterLookup embed, in NT6, the actual record is loaded, so you can do extra work there.

Cheers
Bruce

terryd

  • Hero Member
  • *****
  • Posts: 759
    • View Profile
    • Davcomm
    • Email
Re: Getting the productID as well as the description when using a lookup
« Reply #2 on: February 03, 2012, 02:34:12 AM »
Thanks Bruce
Terry Davidson
Windows 10 64 bit/Windows7 64bit
Clarion 9.1.11529/Clarion10 12567
Nettalk 913
Nettalk 1015
StringTheory267/Winevent515/XFiles298/MessageBox239/Cryptonite186