Freeman35 Posted April 13, 2020 Share Posted April 13, 2020 Hi, why not access to UniApplication.ClientInfoRec in TUniGUIMainModule ? UniGUIApplication added in uses section. Link to comment Share on other sites More sharing options...
Sherzod Posted April 13, 2020 Share Posted April 13, 2020 2 hours ago, Freeman35 said: why not access to UniApplication.ClientInfoRec in TUniGUIMainModule ? Hi, Exactly where do you want to use? Link to comment Share on other sites More sharing options...
Freeman35 Posted April 13, 2020 Author Share Posted April 13, 2020 Hi, in TUniGUIMainModule. in v1484 work code to v1526 trail. This mean somethings changed, never mind. How to access UniApplication.ClientInfoRec in TUniGUIMainModule. 'cos I'm building my connected user info. Link to comment Share on other sites More sharing options...
Sherzod Posted April 13, 2020 Share Posted April 13, 2020 1 minute ago, Freeman35 said: How to access UniApplication.ClientInfoRec in TUniGUIMainModule. Hi, In which event? Link to comment Share on other sites More sharing options...
Freeman35 Posted April 13, 2020 Author Share Posted April 13, 2020 Not in event, I triggred manual my code. User when login correctly enter user & pass then get this infos Link to comment Share on other sites More sharing options...
Sherzod Posted April 13, 2020 Share Posted April 13, 2020 UniSession.UniApplication.ClientInfoRec ... Link to comment Share on other sites More sharing options...
Freeman35 Posted April 13, 2020 Author Share Posted April 13, 2020 Thank you, I think need time break for me Link to comment Share on other sites More sharing options...
alfr Posted April 15, 2020 Share Posted April 15, 2020 Not sure if it's by design or not, but some confusing... What I understand the UniSession.UniApplication.ClientInfoRec record is filled at different times - or more precise shortly after the first form is shown. So to my understanding, the ClientInfoRec can first be retrieved/used in the first Form's AfterShow event? So it can't be used in the mainmodule.create event nor in the LoginForm.create or show event. Below some logging. (In the beginning no text/data in the end of each row. First at "At Login Form AfterShow" there is text/the record is filled) login.exe: 0000382C: 15:39:44 []:Mainmodule: login.exe: 0000382C: 15:39:44 []:BrowserType: login.exe: 0000382C: 15:39:44 []:BrowserVersion:0 login.exe: 0000382C: 15:39:44 []:OSType: login.exe: 0000382C: 15:39:44 []:At Login Form Create: login.exe: 0000382C: 15:39:44 []:BrowserType: login.exe: 0000382C: 15:39:44 []:BrowserVersion:0 login.exe: 0000382C: 15:39:44 []:OSType: login.exe: 0000382C: 15:39:44 []:At Login Form Show: login.exe: 0000382C: 15:39:44 []:BrowserType: login.exe: 0000382C: 15:39:44 []:BrowserVersion:0 login.exe: 0000382C: 15:39:44 []:OSType: login.exe: 00005AC4: 15:39:44 []:At Login Form AfterShow: login.exe: 00005AC4: 15:39:44 []:BrowserType:chrome login.exe: 00005AC4: 15:39:44 []:BrowserVersion:80 login.exe: 00005AC4: 15:39:44 []:OSType:windows login.exe: 00004170: 15:39:51 []:At Login Button click: login.exe: 00004170: 15:39:51 []:BrowserType:chrome login.exe: 00004170: 15:39:51 []:BrowserVersion:80 login.exe: 00004170: 15:39:51 []:OSType:windows login.exe: 00004170: 15:39:51 []:At MainForm Create: login.exe: 00004170: 15:39:51 []:BrowserType:chrome login.exe: 00004170: 15:39:51 []:BrowserVersion:80 login.exe: 00004170: 15:39:51 []:OSType:windows If in the MainModule instead using the BeforeLogin event and there sets Handled to true to bypass the login form - the same pattern occur. The MainForm is then the first form created, so it's first at the MainForm.AfterShow event the record is filled. login.exe: 000055E8: 15:51:57 []:Mainmodule: login.exe: 000055E8: 15:51:57 []:BrowserType: login.exe: 000055E8: 15:51:57 []:BrowserVersion:0 login.exe: 000055E8: 15:51:57 []:OSType: login.exe: 000055E8: 15:51:57 []:At MainForm Create: login.exe: 000055E8: 15:51:57 []:BrowserType: login.exe: 000055E8: 15:51:57 []:BrowserVersion:0 login.exe: 000055E8: 15:51:57 []:OSType: login.exe: 000055E8: 15:51:57 []:At MainForm Show: login.exe: 000055E8: 15:51:57 []:BrowserType: login.exe: 000055E8: 15:51:57 []:BrowserVersion:0 login.exe: 000055E8: 15:51:57 []:OSType: login.exe: 00004068: 15:51:58 []:At MainForm AfterShow: login.exe: 00004068: 15:51:58 []:BrowserType:chrome login.exe: 00004068: 15:51:58 []:BrowserVersion:80 login.exe: 00004068: 15:51:58 []:OSType:windows So seems that this record is filled quite late and can't be used for example early in sessions for logging different types of browsers being used. (I'm also not sure if the functions UniSession.IsMobile and UniSession.IsDesktop have the same limitations - i believe they have or perhaps shouldn't be used? I believe the function UniApplication.UniPlatform is the one that works best - (another option is to use the agentstring directly - UniSession.UserAgent) Just let me know if I've missunderstod anything... UniGui Professional 1.90.0.1523 DemoLoginCookies.zip Link to comment Share on other sites More sharing options...
x11 Posted June 24, 2021 Share Posted June 24, 2021 On 4/13/2020 at 6:34 PM, Sherzod said: UniSession.UniApplication.ClientInfoRec Please tell me in what event to get it in the mobile version. Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now