Jump to content
uniGUI Discussion Forums

wsv01

uniGUI Subscriber
  • Content Count

    37
  • Joined

  • Last visited

Community Reputation

0 Neutral

About wsv01

  • Rank
    Newbie

Recent Profile Visitors

195 profile views
  1. wsv01

    Create a file when running as a service

    Thanks for the info. I tried that. I did figure it out. I ended up using something like this. memo.Lines.Clear; memo.Lines.Add('hello'); memo.Lines.SaveToFile(UniServerModule.ServerRoot + 'files\MyFile.txt'); I was able to use the local system account and get everything to work. I'm not sure this is the perfect answer, but it works for my needs.
  2. wsv01

    Getting a uniGUI Service app running

    I was able to get this running. I'm not sure, but when I renamed the UniServiceModule to UniServiceModule1 it started working.
  3. I have an application running as a service. The service properties are set to log on as the local system account. I have a test set up to try and create a file in the files folder. Here is my code using a TuniDBMemo object. memo.Lines.Clear; memo.Lines.Add('hello'); memo.Lines.SaveToFile(UniServerModule.FilesFolder + 'MyFile.txt'); When I run the application, I receive this error. Why is it trying to create the file in a files folder below the system32 folder? "C:\Windows\system32\files\MyFile.txt".
  4. Being new at uniGUI I created one of my first system in desktop mode. Now I want to take that same application and get it running under a Windows service. If I create a new service type application with nothing in it, it looks like the app is launched using this code if not Application.DelayInitialize or Application.Installing then Application.Initialize; Application.CreateForm(TUniServiceModule, UniServiceModule); Application.Run; From an earlier post, I have set up my project with DEFINES like this When running in VCL, this it how things are started and all works well {$IFDEF UNIGUI_VCL} ReportMemoryLeaksOnShutdown:=True; // Optional. Application.Initialize; TUniServerModule.Create(Application); Application.CreateForm(TUniServiceModule, UniServiceModule); Application.Run; {$ENDIF} When running as a service, I'm assuming this is how things are started. {$IFDEF UNIGUI_SERVICE} if not Application.DelayInitialize or Application.Installing then Application.Initialize; Application.CreateForm(TMyServiceClass, MyServiceClass); // Get from your service module. Application.Run; {$ENDIF} I'm assuming that I have to kick off the project through the ServiceModule? I'm not sure what to change this line to: Application.CreateForm(TMyServiceClass, MyServiceClass); // Get from your service module. If I change to this, and I open the application, I just get a blank browser and it looks hung. Application.CreateForm(TUniServiceModule, UniServiceModule); BTW: I was able to get the application installed as a service and am able to start and stop the server without issues.
  5. I purchased and am using the uniGUI solution for building web pages for customer portals. I did not purchase the mobile feature set at this time. I would like to know if the mobile feature set is able to access the phones features like IMEI number, address book, photos, GPS coordinates, etc. I looked through the mobile objects listed on the uniGUI web site and did not see anything that led me to believe this was the case. IF not, are there other ways to get at this information while still using uniGUI?
  6. wsv01

    Menu dropdown in Chrome not working

    All you have to do is create a new uniGUI stand alone application, add a menu, then add a couple items to a sub menu then run it in Chrome.
  7. When I create a new project and add a menu to the main form, then launch the application, I get a dropdown menu that has up/down arrows instead of showing the menu items when using Chrome. If I select another menu choice, then go back to the one that was not displaying correctly, it now shows the proper sub-menu items. This does not occur in Edge. I have only tried to do this with Chrome and Edge. I am using uniGUI 1.50.0.1480 and creating the application in Delphi 10.2. There was another post in July that may have had the same issue, but no real solution. I have attached two images. One in Edge and one in Chrome.
  8. wsv01

    uniGUI trying to close window on start

    OK, after several days of trying to figure this out, I finally viewed my main form as text and there it was staring me in the face!!!!! Script.Strings = ( 'window.close();') I cannot for the life of me know why I placed that into the Java Script property on the main form, but as you can imagine, when it was removed, the application ran without the message appearing. I'll never forget this one!
  9. I'm still trying to figure out why uniGUI is trying to close the browser window on startup. I had time to run my application on three different browser. IE11, Edge and Chrome. On IE11 and Edge, a window appears With this message The site you're on is trying to close this window. Do you want to close this window? "Yes" or "No" buttons. IF I click Yes, the browser closes and if I click No, the application appears and runs as normal. I launched Chrome and ran debugging and found that the <script>...</script> after the header actually had a window.close() command. It looked like this: <!DOCTYPE html> <html lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <title>Vendor Requistion</title> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=10.0, user-scalable=yes"> <meta http-equiv="content-type" content="charset=utf-8"> <meta http-equiv="cache-control" content="no-cache"> <meta http-equiv="pragma" content="no-cache"> <meta http-equiv="expires" content="-1"> <link REL="SHORTCUT ICON" HREF="/cache/nas_vendreg_exe/87bL9D5OmE1027EDAB5/favicon.ico"> <link rel=stylesheet href="/uni-1.50.0.1480/css/uni-ext.css" /> <link rel=stylesheet href="/ext-6.5.3/build/classic/theme-classic/resources/theme-classic-all.css" /> <script src="/ext-6.5.3/build/ext-all.js"></script> <script src="/ext-6.5.3/build/classic/theme-classic/theme-classic.js"></script> <script src="/uni-1.50.0.1480/ext-unicommon-min.js"></script> <script src="/uni-1.50.0.1480/ext-sync-min.js"></script> <script src="/uni-1.50.0.1480/jQuery/jquery-1.11.2.min.js"></script> <link rel=stylesheet href="/ext-6.5.3/build/packages/font-awesome/resources/font-awesome-all.css" /> <link rel=stylesheet href="/ext-6.5.3/build/packages/font-pictos/resources/font-pictos-all.css" /> <script src="/uni-1.50.0.1480/jQuery/MaskedInput/jquery.inputmask.min.js"></script> <script src="/uni-1.50.0.1480/jQuery/autoNumeric/autoNumeric-1.9.35.js"></script> <link rel=stylesheet href="/uni-1.50.0.1480/css/uni-xtheme-common.css" /> <link rel=stylesheet href="/uni-1.50.0.1480/css/uni-xtheme-classic.css" /> <script src="/uni-1.50.0.1480/ext-unigui-min.js"></script> <style type="text/css">.x-viewport > .x-body {position:relative !important;}</style> <style type="text/css">body {overflow-y: hidden !important;}</style> </head> <script> window.close();;uniVars._extVer="6.5.3";_S_ID="_S_ID=87bL9D5OmE1027EDAB5";Ext.Ajax.setTimeout(1800000);uniSyncObj.errShow=true;uniSyncObj.errText="Connection Error";uniSyncObj.errRetryText="Retrying...";uniSyncObj.errTextColor="#0055AA";uniSyncObj.errAfterRetry=1;uniSyncObj.errLogTry=0x7ef4f2fa;uniSyncObj.licOwn="@@@@@@@@@@@@=";uniSyncObj.srcArr="XJoHutVO"; ... </script> <body> <div id="loading-mask"></div><div id="loading"><div class="loading-indicator">Loading...</div></div> <div id=body></div><noscript>This web application requires JavaScript enabled</noscript></body> </html> The debug text continues, but the rest is not causing issues. I then created a simple uniGUI standalone application with nothing but a button on the main form that ran showmessage('ok'). This time, looking at the debugger I got this: <!DOCTYPE html> <html lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <title>New Application</title> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=10.0, user-scalable=yes"> <meta http-equiv="content-type" content="charset=utf-8"> <meta http-equiv="cache-control" content="no-cache"> <meta http-equiv="pragma" content="no-cache"> <meta http-equiv="expires" content="-1"> <link REL="SHORTCUT ICON" HREF="/cache/project1_exe/APLNDGAwn81027EE02C/favicon.ico"> <link rel=stylesheet href="/uni-1.50.0.1480/css/uni-ext.css" /> <link rel=stylesheet href="/ext-6.5.3/build/classic/theme-classic/resources/theme-classic-all.css" /> <script src="/ext-6.5.3/build/ext-all.js"></script> <script src="/ext-6.5.3/build/classic/theme-classic/theme-classic.js"></script> <script src="/uni-1.50.0.1480/ext-unicommon-min.js"></script> <script src="/uni-1.50.0.1480/ext-sync-min.js"></script> <script src="/uni-1.50.0.1480/jQuery/jquery-1.11.2.min.js"></script> <link rel=stylesheet href="/ext-6.5.3/build/packages/font-awesome/resources/font-awesome-all.css" /> <link rel=stylesheet href="/ext-6.5.3/build/packages/font-pictos/resources/font-pictos-all.css" /> <script src="/uni-1.50.0.1480/jQuery/MaskedInput/jquery.inputmask.min.js"></script> <script src="/uni-1.50.0.1480/jQuery/autoNumeric/autoNumeric-1.9.35.js"></script> <link rel=stylesheet href="/uni-1.50.0.1480/css/uni-xtheme-common.css" /> <link rel=stylesheet href="/uni-1.50.0.1480/css/uni-xtheme-classic.css" /> <script src="/uni-1.50.0.1480/ext-unigui-min.js"></script> <style type="text/css">.x-viewport > .x-body {position:relative !important;}</style> <style type="text/css">body {overflow-y: hidden !important;}</style> </head> <script> uniVars._extVer="6.5.3";_S_ID="_S_ID=APLNDGAwn81027EE02C";uniSyncObj.errShow=true;uniSyncObj.errText="Connection Error";uniSyncObj.errRetryText="Retrying...";uniSyncObj.errTextColor="#0055AA";uniSyncObj.errAfterRetry=1;uniSyncObj.errLogTry=0x7ef4f2fa;uniSyncObj.licOwn="@@@@@@@@@@@@=";uniSyncObj.srcArr="XJoHutVO"; ... </script> <body> <div id="loading-mask"></div><div id="loading"><div class="loading-indicator">Loading...</div></div> <div id=body></div><noscript>This web application requires JavaScript enabled</noscript></body> </html> Notice that there is no window.close() at the beginning of the script. I've tried stepping through the application and cannot find out where this window.close() is being executed from. Any help would be greatly welcome. Note: I don't know if the licOwn= value is something private to my license, so I just replaced it with @@@@@@@@@@@@
  10. wsv01

    Get the EXTJS build

    Sorry for the delay... I just uninstalled everything, restarted the server, moved my licensed standalone EXE to a folder and all ran as expected. Thanks for taking time to give me suggestions.
  11. wsv01

    Not a valid floating point value error on post

    So simple! Thanks so much!
  12. OK, so this is most likely not a uniGUI issue, but I do not seem to have this issue with a standard VCL application. I have a MSSQL database table with a money type column. I have a uniDBEdit control wired to that money column. I have a TFDStoredProc wired to the database table. In that TFDStoredProc I have a persistent field pointing to the money column in the TFDStoredProc. In that persistent field, I have a DisplayFormat of $###,###.00. When I enter a dollar amount in the field on the screen of say 25000.44, the display format takes over and shows $25,000.44. When I try to save the data, I get an error stating $25,000.44 is not a valid floating point value for field xxx. Of course this is because of the "$" and the "," in the display format. How do I get those out of there before the post actually takes place or what properties do I set to resolve this? For whatever reason, I do not seem to have this issue in standard VCL applications. I has to be something quite easy to fix because I cannot seem to find any relevant info about it on the web. I tried a whole bunch of things with no success.
  13. wsv01

    Data cursor moving to first row by itself

    It does not matter how many rows there are. In my own stupidity, I found the issue. On the form OnActivate event I called a procedure that opens the data set. When a form is simply dragged in any direction, it fires off the OnActivate event. Originally I thought it was something to do with the call back, but it really has to do with the form refreshing. I moved the procedure that opens the data set to the OnSHow event and all is well.
  14. wsv01

    Data cursor moving to first row by itself

    A quick update. I think this has something to do with the callback to the window I have the data in. If I simply drag the window a little in either direction, the cursor is refreshed and pointed to the 1st row. I know it's something I do not understand with a window refreshing while there is an open data set in a grid.
  15. I am having this specific problem when trying to remove a row of data from an open cursor. When using this type of syntax attached to a button: MessageDlg('Are you sure you want to delete this record? ', mtConfirmation, mbYesNo, RemoveDocCallback); Then running a callback procedure like this with no code or code in it, the data cursor moves to the 1st row of data by itself. procedure TfrmViewUploads.RemoveDocCallback(Sender: TComponent; Res: Integer); begin end; Let's say there are 3 rows of data in a uniDBGrid shown and I select the 2nd row, then click a button that asks a MessageDlg like above. When Yes is selected, the cursor will move to the 1st row of data by itself. I am using FireDac and connecting to a MSSQL database and pulling data into the cursor via a stored procedure call. If anyone can duplicate this or tell me what I an doing wrong, that would be great.
×