-3

I have two tables first its candidates and second this is employee. Before when i add new employee i have to look up in candidates table and after that take candidateID and add new employee with this key. I dont know how to look up in this candidate tabel. For now i have this but this is bad solution.

set cfname label "First #"
        clname label "Last #" with overlay title "Candidate Name"  1 columns row 5 column  28.
    find last candidates  where firstname = cfname and lastname = clname no-lock no-error .

I want scrolling them and when i press "Enter" i take this key and add in employee table.

create employee no-error.
    Assign
        employee.candidateid = id
        employee.employeeid = next-value(employee)
        hiredate = today.

I dont know how to achive this.

Tom Bascom
  • 13,405
  • 2
  • 27
  • 33
The Reason
  • 7,705
  • 4
  • 24
  • 42

1 Answers1

2

As pointed out: this answers the orignal title of the question "How [to] implement Drop Down Lists in character interface?"

Something to get you started (character interface isn't really my best area so there might be easier ways).

It basically comes down to the VIEW-AS option on the variable definitions as well as some frame definitions.

DEFINE VARIABLE cTest AS CHARACTER   NO-UNDO VIEW-AS COMBO-BOX LABEL "Select value".

DEFINE FRAME fr1
    cTest WITH SIDE-LABELS 1 COLUMN.

cTest:LIST-ITEMS IN FRAME fr1 = "One,Two,Three,Four".

UPDATE cTest WITH FRAME fr1.
Jensd
  • 7,886
  • 2
  • 28
  • 37
  • about this dynamic object i know... i have implement this one in character interface – The Reason Mar 25 '15 at 14:23
  • 2
    I don't understand your comment. SO isn't a very good place to discuss stuff back and forth. If you have a question simply post it as one, if you're lucky you'll get an answer... – Jensd Mar 25 '15 at 14:25
  • This answers the title of the question. But for the life of me I cannot see how the title is related to the body. – Tom Bascom Mar 25 '15 at 18:34
  • @TomBascom I do agree. If I had understood the actual question I would have tried to answer it... – Jensd Mar 25 '15 at 18:54