Jump to content

Tom Chamberlain

Members
  • Content Count

    64
  • Joined

  • Last visited

Everything posted by Tom Chamberlain

  1. This is all High-DPI related issues, if I start the IDE in DPI unaware mode I don't have this problem.
  2. I have had the same issue but with none visual controls like data sources and report builder components, but it is only on some projects. I assume it is a high-dpi issue of some kind or some project setting somewhere.
  3. Tom Chamberlain

    Application.CreateForm : Shows Main form before Application.run

    It has been many years since implementing the method we use now but I remember there being some memory leaks or issues if we never let 'Application.Run' fire. I think it had something to do with possible objects being created in the TfrmMainForm's on create and if you never call 'Application.Run' it never called free on the form or something strange like that. We may have done it this way just to be safe and make sure things got cleaned up under every circumstance. But it looks like the issues was thread related anyway, not related to when the main form was set to visible.
  4. Tom Chamberlain

    Application.CreateForm : Shows Main form before Application.run

    Did you try it this way: Application.Initialize; Application.Title := GF_GetAppName; Application.MainFormOnTaskbar := True; Application.ShowMainForm := False; Application.CreateForm(TPrimaryForm, PrimaryForm); if NOT (pos('-NOSHOW', UpperCase(CmdLine)) > 0) then Application.ShowMainForm := True; Application.Run; We have a class we inherit from TForm that we use to display our splash screen for EXE's and to prompt for user login, the only difference is we terminate the app if they can't pass the login. This way the frmMainForm.Show is not called with Application.CreateForm but it is when the Application.Run is called.
  5. Tom Chamberlain

    Window /client size bug in 10.4

    Maybe something to do with Marco's blog post from January 3rd, here.
  6. Tom Chamberlain

    Showing a warning form to some users

    Agreed, we use a simple DataSnap service for something like this so no 3rd party things are needed as long as you have the enterprise or better version. Create a DataSnap process to run as a Windows service or Linux daemon to be the controller Clients starts and registers itself with the DataSnap service with a call back event so the service can talk back to the client The process that post to the dispatch table also connects to the DataSnap service but to only send a message to the DataSnap service that the record was posted The DataSnap service then sends a message to all or individual clients via the call back This call back is a JSON value so you can pass back whatever you want/need to the client, we pass back 'commands' with multiple other values. After you get it functioning you can add security and encryption if needed. Check here (it was not working for me) and here for some help.
  7. Tom Chamberlain

    RemoteApp

    Microsoft Remote Desktop Services RemoteApp does this, so does VMware ThinApp Virtual Applications. This has nothing to do with Delphi and would probably break some Microsoft license somewhere.
  8. Tom Chamberlain

    Using VMWare: what files remain on host?

    We only install the IDE (+ 3rd party components/tools) and leave the source folders and source control on the host, build DCU/EXE/DLL's to the host share the so other VM's (2019 and Ubuntu) can access them. For dot update 10.2.1 -> 10.2.2 just a simple backup copy of the VM before the upgrade. We try to skip releases so 10.2 -> 10.4 was a clean VM and fresh install of the IDE, all mapped to the same source share on the host.
  9. Tom Chamberlain

    Transforming Data (Pivot ?)

    Create/load a TClientDataSet (or TFDMemTable) on the fly every time the user picks a different DataSet by reading the distinct Settings values within the DataSet and creating columns for each Setting (replace spaces with underscores or something) and if you know the data type of the Setting even better. Then load the data by reading the DataSet and dropping the data into the correct column by the Setting name, when the Instance changes start a new record in the TClientDataSet, repeat. Then you can display the data any way you would like. You could do the same thing with a couple of dynamic arrays, one to hold the columns and another to hold the data if you don't need to know the data type in each column.
  10. Tom Chamberlain

    Help to create a Query and Display the results in a dbGrid

    A simple direct answer: (use of a DataModule and Like are optional and up to you) Drop a new TQuery on the form or datamodule. Drop a TDataSource on the form or datamodule, set the DataSet property of the TDataSource to the new TQuery. Drop a TDBGrid on the form, set the DataSource property of the TDBGrid to the TDataSource. Use a sample SQL statement in the TQuery and activate the TQuery, you should get data in your grid at design time. Right-click the TDBGrid and select Columns Editor. Right-click inside the columns editor property window and select Add all fields to populate the fields in the grid. You can delete the columns you don't want to display in the grid, change the order and you can set the column heading in the Title property. Now this is a quick and easy answer that I would try to avoid myself if possible, there are issues with doing this if you have blob fields or large amounts of data. I would never let the users edit the data this way! If you have access to some other data-ware components besides the base TDBGrid like TMS, Woll2Woll, Steema or Devart you can get a lot more features/functions out of one of those grids. Hand loading a string grid is also a good option if you don't want a data-ware grid, this would be my option.
  11. Tom Chamberlain

    Delphi 10.4.2 custom templates

    I have a set of custom templates that I have used for years, just moved them from version to version, they are simple: fbnc = FieldByName('FieldName').AsCurrency fbni = FieldByName('FieldName').AsInteger ... In 10.3.3 I could do dbSomeQuery.fbnc followed by a CTRL+Space and just press Enter for code completion and position to the highlighted FieldName in the template, in 10.4.2 this does not work. I did not try this in 10.4 or 10.4.1, I was waiting for update #2 😞 If I do a fbnc on a line by itself and hit TAB it works so it is seeing the template, it is like it does like the . before the template name or maybe it does not like being on a line with other code. I have tried changing the delay on the Options -> User Interface -> Editor -> Language (Delphi) -> Code Insight tab, I also tried the Auto Invoke option. Does anyone have a hint on how to make this work in 10.4.2 or is this a new 'feature'?
  12. Tom Chamberlain

    Delphi 10.4.2 custom templates

    Yes it is...so I wait.
  13. Tom Chamberlain

    Delphi 10.4.2 first impressions

    To late for me also, web installer, killed off the Linux and Windows 64bit paths...have a backup to copy from.
  14. Doesn't FMX use DirectX or OpenGL to draw the screen? (I to have no experience with it) VMware ESXi is not the same type of hypervisor as Parallels, VMware Player or VirtualBox but VMware tools must be installed no matter what. A basic ESXi VM's video memory is limited and not indented for graphic intense processes without adding a special 3D hardware card (NVIDIA GRID/AMD Multiuser) to the server. There are 3D software options at a VM level but that can be a CPU hog and depending on the resources allocated to the VM or the Resource Pool the VM is configure in there are other limits put on the performance of a VM like the total workload of the server. Connecting with RDP won't help with this problem, if you have VMware Horizons you may be able to use the VM and Horizons pool 3D software features along with a Horizon Client software or zero thin client with PCoIP or Blast to maybe run better.
  15. Tom Chamberlain

    Delphi with T SQL

    That tutorial is using SQL Lite as an embedded database and is a little different from using something like M$ SQL Server or MySQL where there is another service/process running that you are talking to. That service could be on your computer or on a server were multiple users are talking to it at the same time over a network. You can write SQL commands against them all, but the features and syntax for some functionally changes from database to database and some are not even available. If you want to use SQL Lite you do not need MySQL or M$ SQL Server, you can do everything with FireDAC. I have never used SQL Lite with FireDAC personally. (sometimes I miss the BDE and dbase days, I think I just aged myself) Check this comparison for a sample of just three of the free database out there: https://www.digitalocean.com/community/tutorials/sqlite-vs-mysql-vs-postgresql-a-comparison-of-relational-database-management-systems Also check out: http://docwiki.embarcadero.com/RADStudio/Sydney/en/Using_SQLite_with_FireDAC
  16. Tom Chamberlain

    ICS for Linux?

    And it runs on Windows, Linux and Mac. With a little editing of the vbox file (Virtualbox Machine Definition) you can move/copy your VM's from one platform to another.
  17. There are only two of us now but for years it was just me and I have used SVN for many, many years. Now we do all development in VM's (VirtualBox) and leave the source on the host and access it via virtual share/drive letters, never on the VM's. Source control is good old SVN with TortoiseSVN, all commits/update done from the host. We have an in-house SVN server with repositories for each projects, This makes upgrading version of Delphi simple, we build new VM's for new version of Delphi so we never have cross version compile/component install issues, because that never happens 😮 and use cloned repos for testing new version in new VM's before we ever move production code to a new Delphi version.
  18. Tom Chamberlain

    Your RAD Studio 10.4 Sydney issues

    I received an AV during the installation (twice) and have reported it https://quality.embarcadero.com/browse/RSP-29158 The third attempt (after a restore) worked fine, see my comments in the report.
  19. Never directly expose a database server of any kind to the internet, you are just asking for trouble. Like Hans said a REST service would be better but a VPN connection would be best. You may be able to do a DataSnap server on the local network and make request to it from the outside and have it talk to the FireBird server but you should look at doing it through IIS or Apache and using an SSL certificate to protect your data. Are you using some type of encryption or SSL cert when talking with the Andriod app?
  20. What type of Datasnap server did you make? Standalone EXE (GUI), Windows Service, IIS DLL or Apache module? If it's an IIS DLL or Apache module, then yes you will need the matching IIS or Apache server installed. Is it a EXE or Windows Service, then it run it or install the service and start it. What are you wanting to do with it, simple remote dataset access, remote method calls, passing objects, register and call backs or what? Have you tried the demos and http://docwiki.embarcadero.com/RADStudio/Rio/en/Tutorial:_Using_a_DataSnap_Server_with_an_Application is a good starting point.
  21. Tom Chamberlain

    How to get Linux installed?

    Do you have the PAServer (Platform Assistant) installed on a Linux machine you have access to? The Linux SDK is not included, you have to make a connection to a linux machine via the Options -> Deployment -> Connection Profile Manager or SDK Manager so that the correct includes can be pulled from the linux machine. Use Ubuntu to start with, it is the simplest to get going, here is a video on how to set this up.
  22. Tom Chamberlain

    How to get Linux installed?

    Did you install FMXLinux from GetIt? If not you have to install it first, then right-click on the project (Project1.exe) to get 'Add Linux Platform'
  23. Tom Chamberlain

    Report components: good, bad, ugly

    We have used Report Builder by Digital Metaphors for 10+ years, we also have the TRichView component for great RTF support in and out of the reporting engine. The one time I had a problem they sent me a hot-patch to fix the issue within 24 hours and version to version I cannot think of an upgrade issue we have had, and we started using it in Delphi 7...maybe it has been a little more than 10 years 😮 We have not installed the included reporting software that comes with Delphi since then.
  24. Tom Chamberlain

    Using Delphi in Virtual machine for a month

    If you use VirtualBox do not do defrags from inside the VM, use a tool like CloneVDI. We use this once a month to compact and optimize the VDI files before making backups of the VMs.
  25. Tom Chamberlain

    Using Delphi in Virtual machine for a month

    We have used Delphi in Virtualbox for 10+ years using a separate SSD for the VM makes the biggest improvement and using the extensions help, no AV software in the VM. We keep the source on the host drive with a share to the VM, this lets us upgrade the VM/Delphi faster, source control also lives on the host with the source directories excluded from AV monitoring. We run multiple VM's at the same time, 2012 Server with SQL and our services for a complete isolated (virtual networks) production like environment. No need to ever access the internet from the VM's except for Windows updates. We use i7 laptops with 32GB and multiple SSD/M.2's on docking stations with multiple monitors so the Delphi VM has it's own full screen, the 2012 server is minimized 90% of the day.
×