PC SOFT

FOROS PROFESIONALES
WINDEVWEBDEV y WINDEV Mobile

Inicio → WINDEV 2024 → Table->Form.
Table->Form.
Iniciado por guest, 20,jul. 2017 15:27 - 5 respuestas
Publicado el 20,julio 2017 - 15:27
Hi,

I have a kind of strange behaviour on a combination of window(Table) and window(Form).
When I click on a record in the table, the form is opened and I can change the date. When I keep the form open and click on the table behind the form, the table takes focus again another record can be selected.

Does anybody know how I can prevent, that the table takes focus so the position in the file can not be messed up. Both windows are Free windows,

Thanks for any help.

Best regards,

Aad
Publicado el 20,julio 2017 - 15:34
Hi

windev or windev mobile?

Is the form window opened from the table window or are both windows opened from a 3rd one?

How is the form window open? (code)

Best regards
Publicado el 20,julio 2017 - 15:47
Hi Fabrice,

It's Windev 17 and 22 also. The tablewindow is opened from a menu and the form is opened from the table. The windows come from version 10 or 14 I think where RAD-generated.

IF TableCount(TABLE)>0 THEN
Open("BR_FIC","Modif")
TableDisplay(TABLE,taCurrentSelection) // Re-display the page
EN
Publicado el 20,julio 2017 - 16:05
At the start of the form RAD:Init() is used. When I disable this the problem is gone. I don't know whats happening, so I have to take a close look.
Publicado el 20,julio 2017 - 16:27
Hi Aad,

this is SDI. In MDI a second instance of the Form window would be generated. In SDI you just have to check whether the window is open already - and give a warning plus not opening that window

IF WinStatus("BR_FIC") = NotFound then
Open("BR_FIC","Modif")
ELSE
Error("Window already open!)
END
Publicado el 21,julio 2017 - 10:14
Hi Guenter,

Had nothing to do with the form already open. The table/form combination was an older one generated with the RAD. In the form there was a lot of RAD-code. Some codelines where disabled for some reason. I put them back to work and the problem solved itself

Thank you for your input though.

Best regards,

Aad