Re: Warning message in IDE when running app
Posted: Saturday 4th December 2021 4:59pm
If you set the main forms Persistent property to True then i think it fixes it as the windows config is not destroyed when closing it.
I edited the prog a little to make it also use the "Stop Event" command if arrow keys are pressed with Ctrl otherwise the arrow keys were also changing button focus. using "Stop Event" stops the default key press things happening if you are doing other things
Ignore the fact i used Me.Window.Top and not Me.Top I was experimenting to see if it made a difference.
I edited the prog a little to make it also use the "Stop Event" command if arrow keys are pressed with Ctrl otherwise the arrow keys were also changing button focus. using "Stop Event" stops the default key press things happening if you are doing other things
If Key.Control And [Key.Up, Key.Down, Key.Left, Key.Right].Exist(Key.Code) Then
Moveform(Key.Code)
Stop Event
Endif
and condensed it to run another function..
Public Sub Moveform(KeyCode As Integer)
Select KeyCode
Case Key.Up
Dec Me.Window.Top
Case Key.Down
Inc Me.Window.Top
Case Key.Left
Dec Me.Window.Left
Case Key.Right
Inc Me.Window.Left
End Select
End
Ignore the fact i used Me.Window.Top and not Me.Top I was experimenting to see if it made a difference.