General information
Category:
Forms & Form designer
Title:
Changing between pages... not very well
I'm working with a Pageframe (with Page1 and Page2). Page1 have Grid1 and Page2 have Page2. I'm in Page1.Grid1.textbox and want when I press the F2 key go to Page2.grid2.textbox. Here, in the texbox there is a number xx and when I press the Enter key I want to go to Page1.grid1 and "paste" this number xx.
I know how to do the Keypress, but changing the page not very well. I use this code in Page2 for the Enter key
LPARAMETERS nKeyCode, nShiftAltCtrl
DO CASE
CASE nkeycode=13 && KEY ENTER
THISFORM.PAGEFRAME1.PAGE1.SETFOCUS
KEYBOARD('{ENTER}') ==> to go to last textbox (and row)
KEYBOARD(STR(Table1.number)) ===> paste the number xx from
table1.number
ENDCASE
This work fine but could be better (better tecnic) and have 2 problems
1) When the Page1.Grid1.textbox got the focus, and press enter to
change the control (because this grid have many texbox and a combobox) this grid is not showed right.( if I do a click on the page and then on the grid this problem disapear)
2) I want to paste the number xx in the textbox of the column 2 ( not the texbox of the column 3 or 5)
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