jmac13
Member
Hi all,
I'm using open edge 10.2b
I've created a query on the fly then applied it to browse but when i do num-results("{&browse-name}") it doesn’t work as the Query on the browse has no name. In the help it says the name attribute is a readable/writeable but this doesn’t seem the case for the query object (which is helpful). Is there anyway round this? I've tried using the num-results for my query object but it doesn’t represent whats in the browse.
Example code:
I'm using open edge 10.2b
I've created a query on the fly then applied it to browse but when i do num-results("{&browse-name}") it doesn’t work as the Query on the browse has no name. In the help it says the name attribute is a readable/writeable but this doesn’t seem the case for the query object (which is helpful). Is there anyway round this? I've tried using the num-results for my query object but it doesn’t represent whats in the browse.
Example code:
Code:
define variable chrQuery as character no-undo.
define variable chrQueryWhere as character no-undo.
define variable hanQuery as handle no-undo.
define variable hanTempTable as handle no-undo.
hanTempTable = buffer ttRecs:handle.
CREATE QUERY hanQuery.
hanQuery:SET-BUFFERS(hanTempTable).
do with frame {&frame-name}:
chrQuery = "FOR EACH " + "ttRecs" + " " + chrQueryWhere + " NO-LOCK".
hanQuery:query-prepare(chrQuery).
hanQuery:query-open().
brDetail:query = hanQuery.
/*Browse query name now nothing!*/
intNoRecords = num-results("{&browse-name}"). /*IntnoRecords = 0 now*/
end.