Jump to content

All Activity

This stream auto-updates     

  1. Today
  2. Arnaud Bouchez

    Random Access Violation?

    As David wrote, try to make a minimal reproducible example. Just a project with ODBC access, running a SELECT query. I thought it may have been some problem with FPU exceptions, which happen with third-party libraries, but they usually occur in your Delphi code, not in library code....
  3. A.M. Hoornweg

    FastMM4 and option "AlwaysClearFreedMemory"

    My application needs to call sp_setapprole on MS SQL Server which requires a user name and password. So for a brief time I need these in cleartext form. They are currently stored in an AES encrypted file and I decrypt them on the fly when I need them, using Turbopower Lockbox 2.09. I have no way of knowing if its decryption engine leaves any decoded text in freed blocks on the heap so I thought it would be great if I could simply instruct the heap manager to wipe whatever memory is released. This would prevent the password from appearing in a memory dump. Edit: The actual SQL Query is executed using connection.execute(format('exec sp_setapprole ''%s'', {Encrypt N ''%s''}, ''odbc''', [Approle, Approlepassword])); so I cannot exclude the possibility that the "execute" and the "format" commands might put temporary stuff on the heap as well. [edit] the GitHub feature request you mentioned was mine...
  4. Jacek Laskowski

    Minifing HTML

    You can: - delete end of lines (CR, CRLF) - delete spaces between fields in css: style="color: white; border: 5px" => style="color:white;border:5px" - delete all spaces and tabs of which there is more than one next to each other (except the <pre></pre> tag) - if the styles are defined within HTML in <style type="text/css"> then all long style names like bold_red_important_text can be replaced by short names
  5. Alexander Sviridenkov

    ANN HTML Library 4.1 released

    Yes, duplicates will be removed. You can send me sample HTML to support at delphihtmlcomponents.com, I'll send you back processed HTML and code.
  6. Jacek Laskowski

    ANN HTML Library 4.1 released

    I know that the attribute will not be removed because the library does not know that it is unnecessary. But notice that in the example I gave you, the alt="nothing" attribute appears twice in one tag! This is an example of ugly, junk HTML code that I have to clean up. I would like to do it as automatically as possible, because manual work is very tedious. I imagined that your parser could make it easier for me.
  7. Tntman

    Frequent compilation errors

    I get those errors sometimes, how i deal with it is to just save project and reopen it again and errors are gone.. I know that it is not cool way of fixing it but it works ..
  8. In the latest iOS App requirements and guidelines, one of the requirements says: "Apps for iPhone or iPad must ..... and use an Xcode storyboard to provide the app’s launch screen." Does this mean that a launch image is not enough and we need to create a splash screen inside the app? or this is already handled by Delphi?
  9. Alexander Sviridenkov

    ANN HTML Library 4.1 released

    @Jacek Laskowski, no, only duplicated attributes are removed automatically. Library doesn't know do you need alt="nothing" attribute or not, you should decode this yourself. Duplicated CSS properties can be removed by one line code, but this is not done automatically too, because by default (if there was no style changes) style attribute remains unchanged.
  10. Memnarch

    Adding new Items to the Project Tree?

    In the end, i did summon demons. And succeeded 😄 I'll share what this was all about soon(TM), once the stuff it's for is presentable.
  11. https://www.techradar.com/news/windows-10-has-a-nasty-bug-that-might-affect-people-working-from-home "Microsoft notes that any software which uses WinHTTP or WinInet might (and note that use of the word might – the problem isn’t guaranteed to manifest) experience issues reaching the internet." Just FYI -Tee-
  12. Jacek Laskowski

    ANN HTML Library 4.1 released

    But I mean AUTOMATIC removal of duplicate or unnecessary attributes by library. That's what I'm asking. A library that parses HTML and CSS and creates object-oriented structure (DOM) does it automatically, right?
  13. Jacek Laskowski

    ANN HTML Library 4.1 released

    No, I don't need runtime. But I didn't find a web tool. If you know one, please give me a link.
  14. Lars Fosdal

    Random Access Violation?

    Just to rule out any db access issues - have you tried logging into the database with the same user credential and connection settings as your ODBC connection uses and running the query manually?
  15. begin Memo1.Lines.LoadFromFile('Test.txt'); // loads the entire file as is into the memo It is a bit unclear what you want to do per line, and if it can be automated or not? Do you have a collection of files that you want to merge into the Memo ? var Filename: string; FileContent: TStringList; begin FileContent := TStringList.Create; try for FileName in ListOfFileNames do begin FileContent.LoadFromFile(FileName); // Process it in FileContent here Memo1.Lines.AddStrings(FileContent); end; finally FileContent.Free; end; end;
  16. Out of idle curiosity, does this happen no matter how many cores you have in the CPU? What do the CPU core graphs look like in the Task Manager?
  17. Antony Augustus

    Looking for long term partners/investors

    Hi Nirav, Please let me know when you are available. I can show the demo of the POC I have done. I am based out of India. Evening IST after 9 PM will work the best.
  18. Antony Augustus

    Frequent compilation errors

    Using the compile option for now. Disabled the Antivirus also. So far issue did not surface. Will tell you what caused the problem.
  19. Yesterday
  20. Tntman

    Animating TListViewItem

    Hello members! I started learning delphi few months ago and recently i discovered that we can make really beautiful user interfaces with delphi FMX styles. I saw on the internet this animation demo ( This is just a design ) and I wanted to implement it in delphi: https://thumbs.gfycat.com/ShamelessConfusedAmbushbug-mobile.mp4 I was thinking to use ListView component in FMX for this with ItemApperance -> DynamicApperance. Everything was cool but i faced one problem. Problem is that I am not sure that TlistViewItem can perform animation when it is been added to the ListView. From my understandings i can only animate "Text1" and other items if i add them -> https://i.imgur.com/Y3SWIsT.jpg There is no option ( or I dont know how to find it ) To animate whole TListItemView when is added to a ListView. **WORKAROUND THAT I HAVE ON MY MIND** I was thinking to drop a ListBox and to add on it "TListBoxItem", after that i would right click it and Go on edit custom style, and try to make it look as i want. I tested this tutorial for editing the look of "TListBoxItem" and it is working nicely: https://www.experts-exchange.com/articles/10054/Implementing-a-ListView-in-Firemonkey.html For animation i planned to use this resources ( not tested, i dont know if it will work ) : So what is my question actually, well i would like to achieve similar design and effect from gif that i showed to you. I would like to use ListView with DynamicApperance. I would like to someone confirm me if that is possible and to give me some references or resource material where i could read more about it.. Also if there is someone who would like to give me a code example i would appreciate a lot. From my tests that i performed ( loop 1000 times, and add 1000 items on ListView and ListBox ) I can say that ListBox performed a lot slower so I would prefer ListView for this, also i think that using ListView here is better practice since ListView is more suitable for this situation based on this post: http://www.delphigroups.info/2/8f/544471.html At the end I just want to point out that im using FMX ONLY because i found it easier to make styles, this program is for Windows only platform. I am using Delphi Rio community ( Free version ). I would also like to add that option " Pull to refresh " that you see on that gif is not needed. Thank you for your answers and help! 🙂
  21. David Schwartz

    Minifing HTML

    Aside from the tags that cannot be replaced, and the text that you want displayed, I'm not sure what you can remove. It's not like javascript where you can change all of the variable names to 2- or 3-letter codes and remove most of the white space. What do you imagine can be compressed out?
  22. Dear All 25 years ago I wrote a small database in Pascal for my A Level. 1 day ago I installed Lazarus as I want to code a Delphi Object Pascal project to write .m3u (Playlist) as plain text files, so as to save me manually writing playlist for my mp3 player. Each line is going to be an absolute path to a file that is on the mp3 player. Something like this: \Music\Akmed's Camel\Akmed's Camel\The Boston Flyer.mp3 Granted this is nearly a pointless exercise. I chose it as a starting piece to learn Delphi object programming. I have a simple text file with two lines of text and a third line that is blank. The content was generated by two WriteLn() statements and then the file was closed. Here is the content of the experimental m3u file so far: Hello World more text blank line Next I want to press a button that opens the file and reads in each line and either per line writes the line to a Tmemo object, Memo1.Text := ???? or reads in each line to a string and then pastes the string into Memo1.Text := ????. I want the content to be reproduced over 2 lines. In theory I will then remove items I do not want and paste in items I do want. Here is my attempt so far: procedure TForm1.Button4Click(Sender: TObject); begin AssignFile(myFile, 'Test.txt'); Reset(myFile); while not Eof(myFile) do begin ReadLn(myFile, lineoftext); Memo1.Text := lineoftext; //finaltext := finaltext; end; CloseFile(myFile); // Close the file end; Here is the content of Memo1.Text after clicking the button: more text I have lost the first line and nearly the will to live. I understand that readLn excludes a the newline instruction. That is half my problem. The other half is how to handle the content of each iteration of readLn. The remaining half is how to send the content Memo1. A problem of three halves you might say. Windows 10, 64 bit Free Pascal Lazarus Project, version2.0.6
  23. PeterPanettone

    Improve the Structure Panel?

    Delphi is wonderful for small projects. But if you have a middle-size or large project, the mentioned drawbacks (e.g. the linkage of the structure panel content to the current type of editor) are annoying and time-consuming.
  24. If everything was as you believed then there wouldn't be a problem. The debugger behavior you describe is the same for all versions and is as expected. If you don't want the OS to switch threads during single step then you need to suspend the other threads in the debugger. But you don't really need to single step to locate the problem. Just repeatedly pause the application when it exhibit the behavior you describe and examine the call stacks of the different threads. Sooner or later you will get a snapshop that reveals the cause of the problem. This simple approach almost always work for me.
  25. radekc

    displaying TAndroidNativeView descendant

    Solved, for future: use https://github.com/Zeus64/alcinoe/blob/master/source/ALFmxEdit.pas as example, refactor for your JView.
  26. timfrost

    Random Access Violation?

    I have had a similar problem with external DLLs. In our case we already had an exception handler in the calling C program which caught the exception and could display the stack in our log file. For Delphi main programs, we also use MadExcept which can do the same thing, as do functions available in the JCL. Then use something like Process Explorer to display the load addresses of all the external DLLs in the process before the exception occurs, and DUMPBIN /Exports to display all the entry points of the DLLs involved in the stack. None of this will solve the problem on its own, but having the names of even a few of the functions that appear in the exception stack may give you some clues. The simplest possible example, as David H suggests, will also help.
  27. David Heffernan

    Random Access Violation?

    So often this is caused by a defect in your code. You supply an argument that is invalid. Perhaps an object that has already been destroyed. So full fastmm4 debug is useful. You would debug this by trying to create a minimal example that reproduces the issue. That's the starting point.
  1. Load more activity
×