General information
Category:
The Mere Mortals Framework
I've got a real humdinger, whatever that means! On just a plain vanilla cBizobj form, I have a plain vanilla cPageframe. On page1 I have a single bizobj. The bizobj simply opens some free cursors. The init method of the form runs a query and creates a cursor. A command button runs another query based on a pick list, activates page2, and poplulates my grid. Runs like a charm. I have to reset my grid's rowsource property each time I run the query, but this has never been a problem.
Here's the problem. (Hold on to your seats!) I have a combobox that sets a filter on the cursor. When I try this from the command window it runs fine. Example:
SET FILTER TO HC_CODE='0P'
_SCREEN.ACTIVEFORM.REFRESH()
If I put this code in the valid event of my combobox. I get all kinds of errors. Mostly Operator/Operand mismatch. The error tells that it is in the refresh method of the grid, but the debug window tells me the line of Code in the valid event of my combobox is the culprit.
Here's the code:
LOCAL loSelect
loSelect = CREATEOBJ('cSelect', 'cFinal')
SET FILTER TO
SET FILTER TO ALLTRIM(hc_code) = THIS.VALUE
thisform.refresh()
I have verified that THIS.VALUE contains a valid character value, which matches the value in the cursor. There is no reason why this would work in the command window and not in the form. Especially when I have doene this while the form is running. Any suggestions?
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only