Actually this is kinda timely because I did use the REFRESH first, but it didn't work. I always use REFRESH and never before have needed to use CLOSE/OPEN. Must have something to do with the particular view that the DBGrid is based on, but it never refreshed. It's a 4-table view, because it's looking up the account name to the same table for 3 different columns of the primary table. Here's the definition (formatted to fit this email):
View: vSalesDelWksheet2 (SWID, BLNo, HasNotes, ShipDate, PO, BillTo, Cosignee, Shipper, ActNameB, ActNameC, ActNameS) SELECT t1.swid, t1.blno, t1.hasnotes, t1.shipdate, t1.po, t1.billto, t1.cosignee, t1.shipper, t2.actname, t3.actname, t4.actname FROM SalesDelWksheet t1, account t2, account t3, account t4 WHERE t1.billto = t2.acctno AND t1.cosignee = t3.acctno AND t1.shipper = t4.acctno So I changed it to be a CLOSE/OPEN and then it worked perfectly. So I'm surmising that the search will only work against a REFRESH. Maybe I will prepare an example of this form & the view to demonstrate that it didn't refresh. Thanks for the response! Karen -----Original Message----- From: A. Razzak Memon <[email protected]> To: rbase-l <[email protected]> Sent: Fri, Aug 25, 2017 1:04 pm Subject: Re: [RBASE-L] - Help with DBGrid search command I feel compelled to help this particular post. This may be too overwhelming to comprehend <g>. When developing applications, there are very specific scenarios when you have to use PROPERTY TABLE TableViewName ('CLOSE'/'OPEN') commands. However, based on the specific needs, there are times when you simply have to use the good old PROPERTY TABLE TableViewName 'REFRESH' command. In your specific case, if you wish to retain the highlighted/selected row of Enhanced DB Grid, as is, you will have to use the REFRESH option to accomplish your goal. Here is a coooool example to illustrate the exact use of such PROPERTY command: (See attached screen shots) -- Start -- Enhanced DB Grid -- On Double-Click EEP -- Author: A. Razzak Memon -- Date Created: June 3, 2017 -- Last Updated: August 18, 2017 -- Last Updated: August 20, 2017 -- Last Updated: August 24, 2017 CLS EDIT USING TSSXE_Dashboard_Job WHERE JobID = .vJobID CAPTION 'Job Details' PROPERTY TABLE Jobs_By_Project_Manager 'REFRESH' PROPERTY TABLE Jobs_By_Project_Manager_ThreeDays 'REFRESH' RETURN -- End Variable (vJobID) is a Table based Form Expression, associated with Enhanced DB Grid. That's all there is to it! Very Best R:egards, Razzak At 12:10 PM 8/25/2017, Karen Tellef via RBASE-L wrote: >Using version X, 7/31 build. > >I have a grid based on a view. Clicking in a column runs eep code >that updates the underlying data, >does a CLOSE/OPEN of the grid's view. > >Problem is that I use the focus on the row the user was on. I >thought that the "search" command was the way to go. It traces >fine, no errors, the variable values look correct, but it doesn't >change focus. Focus stays on the first row of the refreshed >grid. Can anyone find an error in my code, or suggest a different >way? I do not want to use "filter" commands because I want all data >to show up. > > SET VAR vOldBLNo = .vBLNo > UPDATE salesdelwksheet SET po = .vPO WHERE blno = .vBLNo > PROPERTY TABLE vSalesDelWksheet2 'CLOSE' > PROPERTY TABLE vSalesDelWksheet2 'OPEN' > SET VAR vCommand = ('PROPERTY TABLE vSalesDelWksheet2 > SEARCH->BLNo->' + (CTXT(.vOldBLNo)) ) > &vCommand > >Thanks for the help! -- For group guidelines, visit http://www.rbase.com/support/usersgroup_guidelines.php --- You received this message because you are subscribed to the Google Groups "RBASE-L" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout. -- For group guidelines, visit http://www.rbase.com/support/usersgroup_guidelines.php --- You received this message because you are subscribed to the Google Groups "RBASE-L" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.

