Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation on 09/04/21 in all areas

  1. Uwe Raabe

    Anybody changing FileVersion directly in dproj file?

    I learned that creating a separate build project is mandatory even for small and/or short lived projects. Alone that it just gives the customer a professional experience when you are able to fix a bug and provide a new setup for download in a few minutes just by committing and pushing the changes.
  2. David Heffernan

    Anybody changing FileVersion directly in dproj file?

    Why wouldn't you automate the build?
  3. haentschman

    Locate

    Hi... Sorry...but 👿 once of many: https://stackoverflow.com/questions/71419/why-should-i-not-use-with-in-delphi
  4. Michael Longneck

    Delphi 10.4, FireDac, StartTransaction causes ODBC error.

    That's happened because somewhere called TFDQuery.ExecSQL or TFDStoredProc.ExecProc but SQL stored proc return result set, which obviously not fetched but not discard. And now any attempt to StartTransaction (internally it's just turn off autocommit) will be failed with this "clear and detailed" error message. There's two options - call Query.Disconnect(True) or call Open instead ExecSQL\ExecProc.
  5. chkaufmann

    TPopupMenu with group headers

    Thanks for all hints. I created a subclass of TMenuItem and did an override of the AdvancedDrawItem method. In addition I set Enabled=False. Themes are not support, but I don't have that anyway in my application. But so far it looks fine: procedure TMenuGroupItem.AdvancedDrawItem(ACanvas: TCanvas; ARect: TRect; State: TOwnerDrawState; TopLevel: Boolean); begin ACanvas.Brush.Color := TColors.Silver.Lighten(50); ACanvas.FillRect(ARect); ACanvas.Font.Color := TColors.SysWindowText; ACanvas.TextRect(ARect, ARect.Left + 3, ARect.Top + 3, StripHotkey(Caption)); end; Christian
  6. Lajos Juhász

    Locate

    This is a bad idea for two reasons: 1.) What will happen when the value is null? It will fail with message that Delphi cannot convert the null to string. 2.) Why would you like to find the field for every record. You should find it before wile and store it in a local variable and use that instead.
×