Hi all.
case1. There is a pageform.p1 main_grid, when i'm double-clicking on the line X, pageform.page2 opens with the "delete" button.
When I click delete: I move to the grid, X is not in the grid.(It's good)
case2. But when I start the application first, then I add rows from another table. And when I want to delete X, I click on the button and move to the main_grid, but the deleted record X is displayed (marked with a black mark) and the focus is set on it. To make line X disappear, I need to click on any other line. How to make it be like in the first case?
Click in main_grid
ThisForm.Pageframe1.page1.Refresh
ThisForm.Pageframe1.page2.Refresh
When i removed ThisForm.Pageframe1.page1.Refresh, then
I noticed that in the first case debugger has BeforeRowColChange AfterRowColChange
case2:
delete button
Note: if I write GO BOTTOM after DELETE, then the deleted record will disappear, but I need the focus to remain in the previous place
case1. There is a pageform.p1 main_grid, when i'm double-clicking on the line X, pageform.page2 opens with the "delete" button.
When I click delete: I move to the grid, X is not in the grid.(It's good)
case2. But when I start the application first, then I add rows from another table. And when I want to delete X, I click on the button and move to the main_grid, but the deleted record X is displayed (marked with a black mark) and the focus is set on it. To make line X disappear, I need to click on any other line. How to make it be like in the first case?
Click in main_grid
ThisForm.Pageframe1.page1.Refresh
ThisForm.Pageframe1.page2.Refresh
When i removed ThisForm.Pageframe1.page1.Refresh, then
stopped working, then the problem is in the page refresh?me said:To make line X disappear, I need to click on any other line.
I noticed that in the first case debugger has BeforeRowColChange AfterRowColChange
case2:
delete button
SELECT main_dir
DELETE
ThisForm.Pageframe1.ActivePage = 1
ThisForm.Pageframe1.page1.Enabled = .T.
ThisForm.pageframe1.page1.grdMain_dir.SetFocus
ThisForm.pageframe1.page1.grdMain_dir.Refresh
*!* ThisForm.pageframe1.page1.Refresh
DELETE
ThisForm.Pageframe1.ActivePage = 1
ThisForm.Pageframe1.page1.Enabled = .T.
ThisForm.pageframe1.page1.grdMain_dir.SetFocus
ThisForm.pageframe1.page1.grdMain_dir.Refresh
*!* ThisForm.pageframe1.page1.Refresh
Note: if I write GO BOTTOM after DELETE, then the deleted record will disappear, but I need the focus to remain in the previous place