Jump to content

Brian Evans

Members
  • Content Count

    323
  • Joined

  • Last visited

  • Days Won

    4

Brian Evans last won the day on February 13

Brian Evans had the most liked content!

Community Reputation

92 Excellent

Technical Information

  • Delphi-Version
    Delphi 12 Athens

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Brian Evans

    Avoid parameter evaluation

    Having the logging expressions compiled and executed on a regular basis means they are less likely to break unnoticed and cause issues when you need them. Building logging strings is usually a small fraction of execution time so keeping things simple is a valid choice.
  2. Brian Evans

    Debugging with Linux target

    Not sure what your setup is - what Linux has PAServer on it to run/debug executables written in Delphi? Are you using your Ubuntu 24.04 host? It is best to use a supported distribution, so Ubuntu 22 or Ubuntu 20.04 LTS if you prefer Ubuntu when debugging. Supported Target Platforms - RAD Studio (embarcadero.com)
  3. Brian Evans

    OSX universal binary file

    You follow: https://docwiki.embarcadero.com/RADStudio/Athens/en/Delphi_Considerations_for_Multi-Device_Applications#Universal_Binaries ?
  4. Brian Evans

    Trying to end a process but failing

    The DLL it is running, and its location should give some hints as to what it is as will the contents (strings at least) of that DLL. Best to figure out what it is and uninstall or disabled it. Sometimes software is installed as a device driver, I remember an annoying piece of Lenovo software that was like that. Other things that can eat a lot of disk IO would be Windows Search indexing.
  5. Brian Evans

    Breakpoints in Debug + Android 64-bit mode.

    They are disabled by default on Android devices. You must enable development mode and then also enable USB debugging. Having them enabled has security implications.
  6. Brian Evans

    'View as Text' command menu item?

    Another issue is IDE insight is blind to context menu commands. This means things only available in a context menu are harder to find.
  7. Brian Evans

    Quality Portal: View my reports?

    The person silhouette in the top right, Requests then in the results change the All drop down to Created by me.
  8. Brian Evans

    TControlList — need help!

    Making a Windows API call for every cell to get the text height will be slow period. The call is required since the text needs to be re-flowed when the width changes. It does all cells to get a new total height. As I mentioned for speed you need a different approach that doesn't need to calculate total height.
  9. Brian Evans

    TControlList — need help!

    A scroll bar that is based on # of rows instead of height and only using enough labels to fill the visible area - swapping/drawing content, as necessary. The drawback is jumpy scrolling instead of smooth due to row at a time vs line at a time, but it is orders of magnitude faster. A lot more work to do it with a ControlList but most grids that support variable row height will do all it for you.
  10. Brian Evans

    Delphi app using Access database very slow on network drive.

    Huge slowdowns on a file server can often be due to failed write cache battery backup on a raid controller with spinning disks attached. With two different customers seeing the issue this is less likely the cause. A local SSD or even HD can hide issues with queries and indexes - scanning a 1GB table is nothing from a local SSD but will be much slower going over the network to a spinning disk. Same if antivirus scans the MDB on first open - much faster locally vs across the network. Can check Resource Monitor and see how much disk reads are required when the application does a query.
  11. Another approach: Code like that suggested by Dave but in the form's MouseMove and leave MouseLeave for the panel blank. procedure TForm1.FormMouseMove(Sender: TObject; Shift: TShiftState; X, Y: Single); var LPoint: TPointF; begin if (ParentPanel.Fill.Color = TAlphaColorRec.Red) then begin LPoint.X := X; LPoint.Y := Y; if not ParentPanel.AbsoluteRect.Contains(LPoint) then ParentPanel.Fill.Color := $FFE0E0E0; end; end; procedure TForm1.ParentPanelMouseEnter(Sender: TObject); begin ParentPanel.Fill.Color := TAlphaColorRec.Red; end; procedure TForm1.ParentPanelMouseLeave(Sender: TObject); begin // ParentPanel.Fill.Color := $FFE0E0E0; end;
  12. In 64bit RAX does not contain the first parameter of your Int2Hex function, RCX does. Looks like there are also other problems with the 64 bit ASM code like where the return value is stored: it should end up in RAX, Ref: Using Inline Assembly Code - RAD Studio (embarcadero.com) Ref: Assembly Procedures and Functions - RAD Studio (embarcadero.com)
  13. Brian Evans

    C++ Builder 11.3 / RenameFile() not working?

    I read the question too fast, the code that should have GetLastError added to see any errors specific to the rename (like file open) is commented out. Delphi equivalent pattern is: if RenameFile(oldName, newName) then ShowMessage('File renamed OK') else ShowMessage('File rename failed with error : '+ IntToStr(GetLastError));
  14. Brian Evans

    C++ Builder 11.3 / RenameFile() not working?

    Normal practice to use GetLastError to see what the problem is when some Windows APIs fail. GetLastError function (errhandlingapi.h) - Win32 apps | Microsoft Learn
  15. Brian Evans

    Using FireDAC with Access accdb file

    Can you set it up and test it in the ODBC Data Source Administrator (32-bit)? It should tell you if the 32-bit drivers required are available/installed. If only the 64-bit drivers are installed the newer versions of this utility will mention it. For example on my system I do not have the 32-bit drivers:
×