CastleSoft Posted November 11, 2015 Share Posted November 11, 2015 I have a requirement which allows automatic login if on the local network (ie. 172.x.x.x.x), and Password/Login if outside the network. So the login form needs to close straight away if it detects 172.x.x.x My first attempt was: 1) Add a Login Form to the WebApp 2) In the Form Show if CurrentIP.StartsWith('172.') then begin ModalResult:=mrOK; self.close(); end But this causes UniGUI to crash with a memory error. Should I be OnCreate/OnActivate/OnBeforeShow to automatically close the form if conditions are OK ? Thanks Quote Link to comment Share on other sites More sharing options...
CastleSoft Posted November 12, 2015 Author Share Posted November 12, 2015 Found it.. UniGUIMainModuleBeforeLogin in the UniMainModule - Set Handled = TRUE.. 2 Quote Link to comment Share on other sites More sharing options...
Abaksoft Posted November 12, 2015 Share Posted November 12, 2015 Good +1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.