This topic is locked

create default value from 2 dropdown fields

10/8/2009 12:55:32 AM
PHPRunner General questions
M
meirco author

First table category

field 1 id

field 2 category

field 3 key1

second table activity

field 1 id

field 2 activity

field 3 key2

third table tasks

field 1 id

field 2 categoryid the lookup returns key1

field 3 activityid the lookup returns key2

field 4 keycode

field 5 task

when adding new tasks i lookup the category and activity in table 1 and 2

I want to pre populate keycode from keycode = key1 + key2

how do you accomplish this .
I'm open to the idea of not using a lookup a pre-defined list woul do.

J
Jane 10/8/2009

Hi,
you can fill keycode field in theBefore record added/Before record updated events on the Events tab.

Here is a sample:

$values["keycode"] = $values["categoryid"]+$values["activityid"];