display tt in browse

Yohn

Member
Hy.
I created a temp-table, and i fill that temp-table. How I can display that result in browse. On my mask i draw browse, and I need to display that temp-table. I created browse witch will be a sum of some table row, and on that row i have two or more valutas, (EUR, USD ... ).

Code example:

FOR EACH tt:
FIND FIRST ttValute NO-LOCK
WHERE ttValute.Oznaka = string(tt.sif-val-obrac) NO-ERROR.
IF AVAILABLE ttValute THEN
ttValute.Iznos = ttValute.Iznos + tt.izn-policrano.
ELSE DO:
CREATE ttValute.
ASSIGN
ttValute.Oznaka = string(tt.sif-val-obrac)
ttValute.Iznos = tt.izn-policrano.
END.
END.
 
did you draw the browse with the appbuilder?
if yes:

  • open the trigger section in the section editor

  • choose your browse on the right combobox

  • choose "OPEN_QUERY" on the left combobox
insert:
Code:
OPEN QUERY brMyBrowsname
FOR EACH tt,         FIRST ttValute WHERE ttValute.Oznaka = string(tt.sif-val-obrac).
tbh i dont get what relation is between these 2 temp-tables. maybe you wanna change that query.


  • choose "DISPLAY" on the left combobox and insert every field you want to display
Code:
tt.fieldname  FORMAT "x"  COLUMN-LABEL "labelname"  WIDTH 2



i think thats the easiest way.
 
Sorry but nothing happens. I still have got sum of row from a row of another temp-table.
Syntax is ok, but i don't have result.
 
i guess the temp-tables are empty when the window starts?

so what you got to do after filling the temp-tables is this:

CLOSE QUERY brMyBrowsname.
OPEN QUERY brMyBrowsname
FOR EACH tt, FIRST ttValute WHERE ttValute.Oznaka = string(tt.sif-val-obrac).
 
Back
Top