February 20, 200223 yr Hi there I was wondering, if my primary key field value changes, is there a way for a field to do another lookup like what a calculation field does? For example, I have in my order_db_lineitems db a product code field that is a primary key and a product name field that is a text field with a auto-enter lookup field. Is there on any way the product code of the lineitems changes that I can tell the field to lookup again? Thanxs Steve P.s - Please don't tell me I need to change the product name lineitem as a calculation field!
February 21, 200223 yr Author But how would you get that script to execute? Is there another type of way other than using that doScript plugin thingy? Thanxs Steve Griff
February 21, 200223 yr You can turn the field into a button and activate a script that puts the cursor in the field, sets the current field's name into a global, starts a loop and then compares status(currrentfield) with the one in the global. When they are not equal, it can do another script.
February 22, 200223 yr I don't understand the problem. If you change a key field, the lookup field should automatically update. What am I missing here?
February 22, 200223 yr Author Bob, What is the lookup field though? Is it a calculation field, or a normal text field that has an auto enter lookup enabled? My field is the text field, and it does not "re-lookup" when the key field changed. (The relationship-link field) Thanxs Steve Griff
February 22, 200223 yr I'm assuming that the lookup field is a text field that has the autoenter looked-up value (based on a relationship) option selected. When the key field in the relationship is changed, the value in the lookup field will update immediately. I've done this many times and it works. It's possible that you may have set some options that prevents changing the value once it is set, but it should be possible to have this work automatically. Aha, just thought of something. If you are using the autoenter calculation option to assign the value from the related file, it will only work once, and then won't update after that. You have to use the autoenter lookup instead. [ February 22, 2002, 01:53 PM: Message edited by: BobWeaver ]
Create an account or sign in to comment