Jump to content

mierlp

uniGUI Subscriber
  • Posts

    572
  • Joined

  • Last visited

  • Days Won

    35

Everything posted by mierlp

  1. haha...of course you don't have to agree with that 😉 My largest application is about 200 forms, 20 data modules and not a single query or dataset on the form. With a dataset you have everything neatly organized and you can address any query/dataset as long as you integrate the DataModule in your form. But also smaller applications are always developed with DataModules. You have to choose the approach that suits you and your application
  2. That's right .. that doesn't work, but that has to do with the fact that loading the database and executing the code may be too fast. In addition, it is never a good idea to put Queries and Datasets on the form, that's exactly what the DataModule are for. I would choose a different setup. Try it with a DataModule then I think you don't have the problem anymore or like in my example. When using DataModules all Querie and Dataset are everywhere available. Having Query and datasets available on a form has no added value, it's the wrong approach for database development. Regards Peter
  3. mierlp

    runtime library

    Hi, You will always have to perform the installation of the runtime package once on the server...just like every other software. That's also when you have to install a certain version of .NET on a server or an update thereof, for example. This also works with an installer. Microsoft update packages can be distributed via a so-called WSUS server to servers that you manage. Maybe it is possible that the person who manages the servers and performs updates with his software he also can include the uniGUI runtime package with an update.
  4. See testcase in MainModule i put the MyConnection component and there you can use you're credentials to connect to you're mysql server mainform contains the query and dataset component form1 contains the dbgrid in the menu menu when you click the option 'Open form with dbgrid' there i open query in form1.Oncreate i set the parameters and it find record 5 testcae - dbgrid locate.zip
  5. I did a simple test within my existing application which uses forms and frames. The frame contains the dbgrid so i tested is like this in the uniFrameCreate event i put this simple code: var P : Integer; begin if not dmType.TypeCountry.Active then dmType.TypeCountry.Active; dmtype.TypeCountry.Open; P := 5; dmType.TypeCountry.Locate('typeCountryID', P, []); Result is the record pointer is to the record with ID=5, see blue line in dbgrid...WORKS Make sure that the variable you use is of type integer!
  6. The Locate method is intended to search for a record; the IndexFieldNames property is intended to sort records on the client. These operations are only performed after fetching all data matching the query. Maybe the problem is that,- at the moment you execute the code, NOT ALL RECORDS are loaded because of TMyQuery.FetchAll = false. Then only the amount of records are loaded which is se by TMyQuery.FetchRows When you you execute code by button maybe all or more records are loaded on that point. So ....set the TMyQuery.FetchAll property to True; and see if it changes the behavior. Regards
  7. MySQL with DevArt components
  8. Hi It depends on what you want to achieve. In your current setup you have no fail-over at machine level. So when VPS - Comapny2.myapp.com fails or is going down then this company can't use the application anymore. You have now made a split by assigning a vps per customer with your uniGui stack (IIS, HyperServer, UniGuiApp and Database) If you want to achieve a fail-over in the event of a machine failure, you must ensure that there is a complete copy on a fail-over vps where the correct ip address is again linked to this vps server. What you could do is run multiple application environments on 1 VPS (vps-A). You then get: - 1 IIS environment - 1 Hyper server - in this case 3 uniGui applications - 1 MySQL installation with its own database per customer A 2nd VPS (vps-B) is an exact copy of vps-A. If you change something on vps-A (eg an update of your application), you ensure that this is automatically synchronized to vps-B. Sufficient tools are available to synchronize the database. vps-B is actually a so-called standby server and is used when vps-A fails There are roughly 2 ways to monitor / realize / check if vps-A is up-and-running - DNS level failover - Server-level failover DNS level A DNS fail over can be setup using online DNS IP failovers but they cost money and many people say they are not as good as doing it on the server level, since at DNS level they check your hosting on intervenes and these can be from 4- 10 mins at any time. A Quick Google search reveals DNS Failover System Monitoring. Server level Normally you would proceed with the following: - Replicate Clone of MySQL on both Servers - Clone the file systems using clusters - Interment a IP fail over using something like UCARP A VPS is a virtual private server, so it is already virtual. There are providers that offer the option of purchasing a disaster recovery plan at VPS level, for example, where they ensure that your vps-A is automatically copied to another server and started again with the same ip address. This is what, for example, hypervisors like VMware do and is called Replication ovh.com offers very extensive possibilities when it comes to failover solutions or disaster recovery https://docs.ovh.com/gb/en/dedicated/ip-fo-move/ A other solutions can be this where you do it self: A second machine is always easy to switch everyone to vps-B during maintenance of vps-A. Then perform maintenance and switch the users back to vps-B and then you do maintenance on it. It is important to first consider what form of continuity and redundancy you want to achieve. Then you can think about the concept and realize it Greetz Peter
  9. Good initiative ..count me in..prefer English
  10. you can try this qz | Home I have no experience with it but it seems to work. You will have to install something locally anyway to address a local device
  11. Hi Sherzod Excuse...works perfectly...think I was still sleepy😴...linked to faulty event 😞but now it works😃.
  12. Hi Sherzod Doesn't work, make form freezing without error message unGIO 1.90.0.1547
  13. Hi Is it possible to have some kind of dropdowncount for a dblookupcombobox like in VCL The dropdowncount limit the records showed when the dbloopupcombobox drops down and also limits the height .
  14. Hi I have 2 questions regarding a uniPanel: When uniPanel.BorderStyle = ubsSolid how can i change the border color ? How can a make individual border sides visible/invisible...sometimes i only need to show the left, right and bottom border but not the top border, how to make in invisible? Regards Peter
  15. hi I have a event management system for events en festival is also create invites with qr-code but without any problem What i do is when a user is added to the database i create a 19 digit unique 'barcode' number based on date+date...till milliseconds and the number is stored in the database....you need it for scanning. you can do it on the OnNewRecord event of OnBeforePost What i see from you code is that you created on the UnimFormCreate and possibe the same values are use for creating the qrcode number. I use fastreport to to create the qrcode imge...i have a report with the format off a general phone screen. Now can I set up other information besides the qr code like event name and entrance location and date/time
  16. Hi Take a look on the forum Google Keywords : SEO (Search engine optimization) ? - Feature Requests - uniGUI Discussion Forums Showing results for 'seo'. - uniGUI Discussion Forums
  17. Hi Dominique There are a number of issues that can make it difficult to investigate where the issue is: - you have moved from TransIP to Xenius (2 different environments) - you go from Server 2016 to 2019 - how is the server park accessed over the internal network .. 10GB? - both use different hardware for their VPS environment - which hypervisor to use for the VPS servers (Microsoft Hyper, VMware ESX or ...? More CPU, Memory and Disk is not always a guarantee that something is faster, especially with a VPS server. It mainly depends on the underlying layer and the configuration of the hypervisor. When does the problem occur: - when a user accesses the application through his browser / environment? - does it also occur when you are logged in to the server and start and use the application there? - it also occurs when, for example, you upload 5 GB of data to the server, compared to the 2016 server Some performance issues are known in combinations, for example of Dell hardware, Hyper-V and Windows 2019, but also other performance issues between 2016 and 2019. Do other applications run fast/normal or can it be traced back to uniGui? There are Server 2019 environments where they reconfigure network disclosure so that it behaves more like a Server 2016 environment: LAN Set-NetTCPSetting -SettingName "DatacenterCustom" -CongestionProvider DCTCP Set-NetTCPSetting -SettingName "DatacenterCustom" -CwndRestart True Set-NetTCPSetting -SettingName "DatacenterCustom" -ForceWS Disabled Set-NetTCPSetting -SettingName "Datacenter" -CongestionProvider DCTCP Set-NetTCPSetting -SettingName "Datacenter" -CwndRestart True Set-NetTCPSetting -SettingName "Datacenter" -ForceWS Disabled WAN Set-NetTCPSetting -SettingName "InternetCustom" -CongestionProvider CTCP Set-NetTCPSetting -SettingName "InternetCustom" -DelayedAckTimeoutMs 50 Set-NetTCPSetting -SettingName "InternetCustom" -ForceWS Disabled Set-NetTCPSetting -SettingName "Internet" -CongestionProvider CTCP Set-NetTCPSetting -SettingName "Internet" -DelayedAckTimeoutMs 50 Set-NetTCPSetting -SettingName "Internet" -ForceWS Disabled This reconfigures 2019 to behave a little more like 2016.
  18. Hi Your problem regarding question 1 will also be solved. Because now a record in the value table is linked to a user. In your previous case, you didn't have that and the record didn't belong anywhere and was visible everywhere. In addition, I would not use a dbnavigator but just buttons that you turn on / off based on the status of your DataSource. The text is dutch but is as follow: NIEUW = New (button is default enabled) BEWAREN = Save (button is default disabled) ANNULEREN = Cancel or Close (button is default enabled) Then on the datasource.OnStateChange event i use the following code: // Form is already created if UniMainModule.GetFormInstance(TFormTypeCateringEdit, False)<>nil then begin // Database in WEERGAVE modus FormTypeCateringEdit.btnAdd.Enabled := TypeCatering.State in [dsBrowse]; FormTypeCateringEdit.btnSave.Enabled := TypeCatering.State in [dsInsert,dsEdit]; FormTypeCateringEdit.btnCancel.Enabled := TypeCatering.State in [dsBrowse,dsInsert,dsEdit]; end; As you can see in the code above: button NIEUW / NEW is enabled when the database is in Browse mode button BEWAREN / SAVE is enabled when the database is in Insert or Edit mode so you can save the record button ANNULEREN / CANCEL is enabled when database is in browse,insert or edit mode. This because you want to have a cancel function when you either add a new record or change an existing record in addition, the button closes the form. When the database is in insert / edit mode the function is CANCEL database action. When the database is in browse mode the function is CLOSE
  19. Hi Sergio, The big difference is that you now go from single user to multi-tenant use. Your VCL application runs stand-alone and now you go to the web and the user is only allowed to see his own records. That is multi-tenant use within your application. You can easily solve this by creating a separate table with users and a seperate table for the value. You give them a username and password. Every registered user, and therefore record, has a recordID (unique number). After logging in you can, for example, use a variable to link the recordID or use it as a parameter in your query to make a selection from all records of this one user. When the user creates a new record in a database, you save the user recordID into the table. (OnNewRecord event) So you will have to do a small redesign of your data model: - 1 table for users - 1 table for the values When the tables are filled they will look like this for example After the user has logged in and you use the recordID to select the records in the table 'Values' (at the right), he only sees his records. In this example you are logged in as Sergio and only the records in the VALUES table with UserID = 1 (Sergio) will be showed
  20. Hi I use additional components for multi-language www.regulace.org or www.tsilang.com Of course you can also do it yourself with the help of a database in which you place the translations. My preference was for an existing and working solution that I can use directly for Win32 and uniGui applications. The work you have to come up with something yourself takes me more time than the purchase of a component ... but that is of course different for everyone
  21. Thank you @Sherzod this works fine for me
  22. Hi Sherzod, Does not work...with this code the application doesn't start up anymore. When i disable/mark-out the code in afterrender, mouse-over,mouse-out the application start.
×
×
  • Create New...