Jump to content

Leaderboard


Popular Content

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

  1. corneliusdavid

    Delphi 11 Alexandria: New Edit Window

    Just because it doesn't have features you think are necessary doesn't mean it's useless. I really like this new window as I can open this up and move it to a second monitor so I can see either a different section of the code or the design view of the form while editing the code. In this use case, it wouldn't make sense to have it dockable. Also, I wouldn't need it for every unit, just occasionally for some forms or data modules--when I need it, the feature is there. I can see the benefit for making it dockable and saving it as part of a desktop layout but that's not the first thing I thought of. I'm glad they added this feature. Perhaps there will be a dot release with enhancements you suggest.
  2. Achim Kalwa

    read integer value from database, best practice ?

    Which Database system do you use? Which connection components? If the field in the database is declared as "Integer", it should never contain a Space character. It could be NULL, which means it doesn't contain any value. Most database access components will translate NULL to the value 0, so an empty field should not raise an exception. Which value do you expect in case the field is NULL? To be save, you can test for empty fields yourself: var F : TField; F := Qry.FindField('IntegerField'); if Assigned(F) and (not F.IsNull) then aObject.IntValue := F.AsInteger else aObject.IntValue := -1; // or whatever value you choose in case of an empty field.
×