Jump to content

dummzeuch

Members
  • Content Count

    2857
  • Joined

  • Last visited

  • Days Won

    101

Everything posted by dummzeuch

  1. dummzeuch

    Separate Formatter Issue/Warning..

    It shouldn't matter whether you run that batch file as admin or not. It only adds entries to HKCU in the registry.
  2. dummzeuch

    Separate Formatter Issue/Warning..

    Source/Formatter/GX_CodeFormatterExpert.pas Or even earlier: Source/Formatter/GX_eCodeFormatter.pas
  3. dummzeuch

    Separate Formatter Issue/Warning..

    Could you please add e.g. a messagebox call to the expert's execute method and check whether it shows that message?
  4. dummzeuch

    Separate Formatter Issue/Warning..

    What exactly do you mean by ? Is the menu entry disabled? Is it enabled but the formatter does nothing? Do you get an error message? Any message at all? I simply can't imagine what this tool might do that prevents the GExperts formatter from working. Maybe setting the editor buffer to read only? But then you wouldn't be able to edit your code.
  5. dummzeuch

    GExperts formatter in 11.3

    Thanks for the confirmation. I'm only now updating my Delphi installation to 11.3. And also thanks for the donation.
  6. dummzeuch

    GExperts formatter in 11.3

    Did you use the (old) installer? If yes, compiling and replacing the DLL will probably work. I haven't installed 11.3 yet. The download has finished thought.
  7. It most certainly is. I've never been surprised by how cheap a product is, when I had to ask for a price. On the other hand it's sometimes worth to ask for a discount when the price is published.
  8. dummzeuch

    OMG, that Edit Path expert is awesome

    Fixed. I forgot to call InitDpiScaler in the constructor.
  9. dummzeuch

    OMG, that Edit Path expert is awesome

    Just so nobody gets disappointed: That expert is only available for Delphi 2009 and later. Delphi 2007 and older are lacking the OTAPI support for it. Here is the original blog post.
  10. dummzeuch

    OMG, that Edit Path expert is awesome

    If I remember correctly there is a splitter between the edit memo and the inherited list. But I think the position isn't saved (yet). Is that screenshot from the Delphi 11 version? On a monitor with > 100% scaling?
  11. dummzeuch

    OMG, that Edit Path expert is awesome

    I call GExperts experimental because I don't want anybody thinking that it has been thoroughly tested. Way back, when there actually were several people working on it and many more testing it, there were stable releases. Today I'm the only developer (apart from some very few contributions from others, for which I'm very grateful) and my time is very limited. I simply can't test with all Delphi versions, so only those that I use regularly (currently 2007, 10.2 and some XE2) could be called kind of stable.
  12. dummzeuch

    VCL - DevExpress

    If I hadn't seen this post before reading the previous one, I wouldn't have recognised the sarcasm there either.
  13. That's no alpha symbol in your template, that's a lower case sigma. (Or it's the forum software that broke it.) Care to share those templates?
  14. dummzeuch

    Update an application automatically

    It's DxGettext. If I disable translations, renaming the file works with SysUtils.RenameFile, with the Explorer and also with the Rename command. Man wird alt wie 'ne Kuh und lernt immer noch dazu.
  15. dummzeuch

    Update an application automatically

    That's really odd. I just tried it because I couldn't believe it: VCL-Application with a form and a button b_Rename and the following code: procedure TRenameExeTest.b_RenameClick(Sender: TObject); begin RenameFile(Application.ExeName, Application.ExeName + '.old'); end; Works as expected or rather as not expected by me. Now I wonder why the Explorer and the Rename command cannot do this. Interestingly, after the program has renamed its own executable, it's possible to rename it back using the Explorer. And even more strange: This program can be renamed with the Explorer while its running. The one I tried first (last post with the screenshot) could not. I wonder what causes this. Maybe it's DxGettext that keeps the file open because it accesses the linked in translations? Or JclDebug accessing the jdbg information in the file?
  16. dummzeuch

    Update an application automatically

    Hm, neither Explorer nor the rename command on the commandline can rename an executable that is currently running, so I have so far assumed that's not possible.
  17. dummzeuch

    Error in module rtl200.bpl

    That's actually a good thing: It's easily reproducible. Are you using any plugins? If yes, disable them and try again. Does it still happen every time? If yes, it's the IDE and you probably can't do anything about it (apart from reporting this bug to Embarcadero, of course). If not, enable these plugins one by one and every time try it again. This should tell you which plugin is causing the trouble. In that case report the bug to the plugin maintainer.
  18. dummzeuch

    Update an application automatically

    Are you sure that is what it does? As far as I know only DLLs can be renamed while in use, but not EXEs (*1). (*1: Unless the EXE is located on a Samba-Sever share but then it can only renamed directly on the Unix/Linux box and if you do that it will come back to bite you.)
  19. I just spent some time testing ChatGPTs ability to "understand" and explain Delphi source code. The results were actually quite good. I asked ChatGPT "what’s wrong with the following Delphi code?" function IsoStringToDateTime(const ISODateTime: string): TDateTime; const ISOShortLen = 19; ISOFullLen = 23; var y, m, d, h, n, s, z: Word; begin // ISODateTime should be in one of these formats: // YYYY-MM-DDTHH:NN:SS, YYYY-MM-DD HH:NN:SS // YYYY-MM-DDTHH:NN:SS.ZZZ, YYYY-MM-DD HH:NN:SS.ZZZ if (Length(ISODateTime) <> ISOShortLen) and (Length(ISODateTime) <> ISOFullLen) then raise EConvertError.Create('Invalid ISO date time string: ' + ISODateTime); y := SysUtils.StrToInt(Copy(ISODateTime, 1, 4)); m := SysUtils.StrToInt(Copy(ISODateTime, 6, 2)); d := SysUtils.StrToInt(Copy(ISODateTime, 9, 2)); h := SysUtils.StrToInt(Copy(ISODateTime, 12, 2)); n := SysUtils.StrToInt(Copy(ISODateTime, 15, 2)); s := SysUtils.StrToInt(Copy(ISODateTime, 18, 2)); z := StrToIntDef(Copy(ISODateTime, 21, 3), 0); // Optional Result := EncodeDate(y, m, d) + EncodeTime(h, n, s, z); end; and also "What does the following Delphi function do?" function FileSizeToHumanReadableString(_FileSize: Int64): string; begin if _FileSize > 5 * OneExbiByte then Result := Format(_('%.2f EiB'), [_FileSize / OneExbiByte]) else if _FileSize > 5 * OnePebiByte then Result := Format(_('%.2f PiB'), [_FileSize / OnePebiByte]) else if _FileSize > 5 * OneTebiByte then Result := Format(_('%.2f TiB'), [_FileSize / OneTebiByte]) else if _FileSize > 5 * OneGibiByte then Result := Format(_('%.2f GiB'), [_FileSize / OneGibiByte]) else if _FileSize > 5 * OneMebiByte then Result := Format(_('%.2f MiB'), [_FileSize / OneMebiByte]) else if _FileSize > 5 * OneKibiByte then Result := Format(_('%.2f KiB'), [_FileSize / OneKibiByte]) else Result := Format(_('%d Bytes'), [_FileSize]); end; The answers will surprise you. And these were the shocking answers. The answers were actually quite interesting.
  20. Which only goes to show that the definition of "intelligence" is still very difficult, or at least is used very narrowly in the context of "artificial intelligence".
  21. You could aks ChagGPT to look for bugs in these. 😉
  22. I wasn't aware that I did that. Did I?
  23. I didn't expect it to perform that well, in particular the descriptions it gave for what those functions do. I found that interesting. These were simple tests where I knew the correct answers. It might be helpful in cases where I don't know the answers. Our possibly not. The code I'm usually dealing with is much more complex than a simple function. But you never know. Regardless of whether it will ever be helpful, I had some fun.
×