Jump to content

estrify

uniGUI Subscriber
  • Posts

    454
  • Joined

  • Last visited

  • Days Won

    14

Everything posted by estrify

  1. Hi, I don't know if this could help: I tried your code with no issues except the need to ensure that the directory exists before the "SaveToFile" System.SysUtils.ForceDirectories(ExtractFilePath(UniServerModule.StartPath) + 'myroot'); Regards,
  2. Hi, Take a look to this topic. It might help. Regards,
  3. Sorry if I didn't understand you correctly. Usually I shutdown the server via the tryicon "Shutdown" option. Other stop procedures are only reserved for errors during the startup of the server. Keeping this in mind, "UniServerInstance.TerminateStandAlone()" works to get out securily of server startup errors (address/port in use, configuration errors, etc.) inside "UniGUIServerModuleException" and "UniGUIServerModuleServerStartup" procedures. I believe that "Halt" or "ExitProcess" are abnormal exit procedures, so they should be used with care. To stop the server via command, in fact "ExitProcedure" is what I do but just in case making sure to previously close all sessions and all backend threads that were active on the server. Due to those threads, if you have them, make sure none of them are still running before "ExitProcedure". One question: how do you remove UniGUI's tryicon?
  4. Hola, FileExist lo está ejecutando el sevidor, por lo que es normal que encuentre el fichero. <img></img> lo está ejecutando el navegador, que le pide un fichero al servidor con un HTTP o lo intenta resolver localmente. Eso significa que, si no pones nada, la petición se hace relativa a https://direcciónIP, por lo que el servidor no lo encontrará porque no entiende la URL; o bien a file:// y entonces lo que intenta el navegador es abrir un fichero local, en el cliente, pero habitualmente lo que quieres servir no lo tiene accesible el cliente, sino el servidor. Una posible solución a esto es, en el servidor, mapear el directorio que quieras de la red con un symbolic link dentro del directoio imagenes. Por ejemplo (hazlo con un CMD con privilegios de administrador): net use "\\servidor\d\imagenes" mklink /d "tu directorio imagenes local\imagenes en red" "\\servidor\d\imagenes" así cuando uses <img src="imagenes/imagenes en red/1.png" height="200px" width="auto"></img> lo encontrará porque la petición será https://direcciónIP/imagenes/imagenes en red/1.jpg e "imagenes en red" lo tienes mapeado a tu directorio de red. En IIS puedes hacer algo parecido para mapear directorios, a nivel de IIS no a nivel de sistema operativo, aunque allí no te puedo ayudar porque no lo uso... Un saludo,
  5. Hi, Use the "OnClose" event of the form: procedure TMainForm.UniFormClose(Sender: TObject; var Action: TCloseAction); begin if <some condition> then Action:= caNone; end; Regards,
  6. Hello, I don't know if this can help you: I use UniServerInstance.TerminateStandAlone(); Always called from ServerModule. One question: Do you hack the existing tryicon to include your options or create a completely new one?
  7. Dear UniGUI team, I have a problem that I need your advice on how to tackle it. I have a good set of queries that can generate a quite big rows of results… After doing all server-side filtering (in the SQL), depending on user profile but the “most powerful” profile can receive about 300.000 registers with 30 columns (from tables with millions of entries). I think the normal sequence in a UniGUI project is the following: 1. MySQL Server executes the query and returns it to UniGUI server. As I can only use client side cursors with UniGUI controls, this huge amount of data travels from MySQL to UniGUI servers, consuming network resources and time. 2. UniGUI server sends much less amount of data to UniGUI client with a tipical paged DBGrid, so this is done quickly. Filters and sorters of a DBGrid manage temporarily stored data in UniGUI server, so those operations are very fast. So, the problem is the point 1. Is there a way to use server cursors and avoid this traffic of data from MySQL to UniGUI server?. I think I can’t but I am not sure if this is right or not: with server cursors, UniGUI components can’t use tools like “Recordcount”, so a DBGrid can’t use, for example, its classic pagination system, neither client side filtering, sorting, etc. Is there a way to configure a DBGrid to work properly with server cursors?. If so, this will save my life, temporarily, because it will give me some time to develop the following (if it is not done within UniGUI, but I think not): To create a custom system to replace a large handful of very useful features of UniGUI's DBGrid: pagination/infinite scrolling, grid filters and sorters. That is, using a DBGrid without paging and implement a totally new paging system doing "SELECT COUNT()" to retrieve the number of rows, use my own controls to do pagination and link it to SQL's "LIMIT OFFSET, ROWS" to retrieve only one desired page. And, obviously, disable all client side filtering and sorting and replacing it with server side filtering and sorting. I am sure that I am not the first guy with this kind of problems, and may be UniGUI can be configured to work this way, but I don't know how. So if you have indications/sample projects/tips/best practice/etc. to do so, I will be very grateful. Best regards,
  8. Thank you very much ... it is very helpful.
  9. It's a great idea!!!... I like it... But I still haven't received the verification email yet .. Here it is !!!
  10. Thanks a lot... Sure it is what I need and excuse me for not having found it myself with the search engine of the forums...
  11. Dear Sherzod, I would be very pleased if you could help me with this issue, I have a TreeGrid using IdField-IdParentField feature The user has collapsed and expanded some nodes os his interest From time to time, the user needs to push a button to refresh treegrid's data After refreshing the TreeGrid, all nodes has been collapsed How can I maintain expansion/collapstion states of nodes after a refresh? As always, thank you very much in advance,
  12. No ideas about why this simple secha example doesn't wotk with UniGUI unless embedded data is used?. Have I to import a missed lib, do something in another way, ...?. Why?
  13. Hi, In the test case attached, I am trying to find why an UniHTMLFrame works with a store with embedded data but do not with a proxy store pointing to a json file having the same data. It is related to how UniGUI works or simply am I forgetting something?. Thans in advance, TreeGrid.rar
  14. Perfect!!! As usual ... Thank you very much... Please, could you take a look at this one? http://forums.unigui.com/index.php?/topic/14036-no-scrollbars-when-mfpagetrue-and-autoscrolltrue/ It is more important to me than it seems ... Thank you in advance...
  15. Hi, I need to add a title or convert first item into one in a popup menu. Has anyone a sample of how to do so? Thanks in advance...
  16. Or not to use Hyperserver everywhere , because in this type of applications, the concurrency is very low since here UniGUI acts only as management interface. This type of application is extremely portable because it only needs the unigui runtime installed on the machine. Perhaps a property like "force kill" could be useful in Hyperserver configuration, or a "timeout to kill" property. Please keep it in mind if you have time to think about it and doesn't take much effort to implement it. Another mechanism that could be useful is to deploy a new binary using a ServerModule method (with a path to the new binary as an argument), in addition to the current manual procedure. This can be used to update the app automatically when it receives a message to do so. Thank you very much for clarifying how this mechanism works. I like it very much, and I am looking forward to Server Farm feature. It can be just amazing.
  17. This is exactly what I do, i.e. to exit the application., But some times, some threads could need several minutes to finish (I.e. making a dump and compression could take about 4 minutes, synchronize with external system could take from 1 to 10-15 minutes, depending on the volume of data to synchronize). So the recycling process will wail or will force killing the process?
  18. Dear Hayri, I have one more question: I have one application that manages several tasks in background with threads periodically launched from ServerModule (those tasks do not interact with GUI, only perform tasks in database, network drives and interact with other applications). I suppose that I can use "Persistent Node Zero" feature to ensure the control of my threads but, what does "it will be occasionally recycled like any other Node" mean exaclty?. How can I ensure that this recyclement is done when there are no threads in execution? Thanks in advance and regards,
  19. Thanks a lot for your answer and recommendation, I will try... As you do, I also think restarting server is only necessary first time to adjust OS parameters. Once done, it is enough stopping, uninstalling, installing and starting. But as this is the first time I will use it in production, I needed to be sure about it.
  20. Thank you very much for the answers!!!. Now I have it much clearer... Only one additional question: Is it necessary the restarting of the server after each installation?
  21. Dear UniGUI team: I would be pleased if you could replay following questions because I just upgrade to use this feature (Hyperserver) and I need to be sure about some basics: Hyperserver can create, recycle and destroy nodes, so it can move active sessions from one node to another. The sessionId actually has something like the node where it is created at the beginning of the string, has it?. So, when a session is moved from one node to another, it will maintain its whole session Id indicating on which node it was created, is this true? Is there a way for a session or its application to know on which node is running now?. This feature would be desirable, in addition to events in UniMainModule to signal leaving and entering node. This could help a lot when globally managing sessions. When Hyperserver moves sessions from one node to another, does it move each session individually, grouping them or all of them at the same time, in a kind of transaction? If the session to be moved has thrown a thread, will the thread be accessed correctly after the movement? Assuming that the Hyperserver installer was installed once in the deployed machine and restarted, when upgrading the version of unigui, is it necessary to use again the hyperserver installer on deployed machine or it is enough distributing the exe or the dll of the hyperserver? Thank you in advance, Regards,
  22. Simply impressive!!!... This library is spectacular...
×
×
  • Create New...