

Lajos Juhász
-
Content Count
1078 -
Joined
-
Last visited
-
Days Won
15
Posts posted by Lajos Juhász
-
-
10 minutes ago, Sherlock said:Given the complexity and the tendency of developers to always suggest some totally different approach
, here is my completely different suggestion. You seem to have the need to validate an e-mail address before storing it. How about sending a test mail before doing that. That way you get to birds with one stone: Verify the address, and get the permission to use it... a must have in Europe.
This is an excellent suggestion. I doubt it is a must in Europe, I still receive sensitive information for other people in my e-mail account.
-
you should double check the path of the file the package tries to load. If the name of the dll is same for 32 and 64 bits there is always a possibility that windows first locates the 32 bit version.
-
You have to replace /local/path/file.jpg with your pdf file and type=application/pdf.
-
4 minutes ago, Anders Melander said:Even if you don't have a need to write assembler, knowledge of it makes you a better developer because it gives you a deeper understanding of what's going on and why. The same goes for hardware.
I wrote that in context that Asm has more than twice the rating of Delphi. I simply cannot believe that's true.
-
For me Assembly language makes no sense. I wonder in 2022 who is still coding using asm (I doubt it's used widely in windows applications).
-
If you are looking for the Registered Prodducts portal you can find it at https://my.embarcadero.com.
-
1
-
-
16 hours ago, David Heffernan said:Stefan is talking about a different algorithm, modified binary search algorithms know as lower or upper bound binary search. Kind of the entire point of this topic.
My point was with that Wikipedia link that modified algorithms have their names. Like in the link the variation to find the elemest with lowest index is called binary_search_leftmost and not binary_search.
16 hours ago, Anders Melander said:Wikipedia (even though it references the almighty Knuth) isn't the definition". It's a definition.
That's true, but most developers expect that if an implementation reference to an algorithm it will implement that algorithm and not something else. That was the whole point to name algorithms in matemathics and computer science. That no matter from where you learned an algorithm you know how it works.
-
1
-
-
3 hours ago, Stefan Glienke said:Not true - in a lower bound binary search you keep on binary searching until your range got down to 1 element - with a loop you turn O(log n) into O(n)
This is the definition of the binary search: https://en.wikipedia.org/wiki/Binary_search_algorithm
"The procedure may return any index whose element is equal to the target value, even if there are duplicate elements in the array. For example, if the array to be searched was {\displaystyle [1,2,3,4,4,5,6,7]}{\displaystyle [1,2,3,4,4,5,6,7]} and the target was {\displaystyle 4}4, then it would be correct for the algorithm to either return the 4th (index 3) or 5th (index 4) element. The regular procedure would return the 4th element (index 3) in this case. It does not always return the first duplicate (consider {\displaystyle [1,2,4,4,4,5,6,7]}{\displaystyle [1,2,4,4,4,5,6,7]} which still returns the 4th element). "
-
I doubt, this is by definition how Binary search works. To get the lowest index you just to iterate from the matched item and find the lowest index.
-
2
-
-
1 hour ago, saeedbay said:how i can have an acount of https://quality.embarcadero.com
written there please contact your JIRA administrators.
It's the same as you Embarcadero account.
-
It's hard to verify code this large. One thing you're for every step create a query:
gisShapeTypePolygon: begin qryUID := TADOQuery.create(self);
This is not going to be a definite leak as it has self (most probably the form as the owner). The query will remain open until the owner is destroyed.
-
That's not what I have Size: 1.80 MB (1,894,304 bytes) and my coy was signed by Idera, Inc.
-
30 minutes ago, David Heffernan said:Interestingly, if the process has UTF-8 as the active code page (ccchttps://learn.microsoft.com/en-us/windows/apps/design/globalizing/use-utf8-code-page) then you can use AnsiString fine and be fully Unicode compliant. I discovered this by accident lately when my MATLAB mex file, which uses ANSI because MATLAB doesn't do UTF16, unexpectedly started handling Unicode with a recent MATLAB update! The update set this code page in its manifest.
Yeah, and breaks FireDAC as it converts from UTF-16 using the language for non-unicode programs instead of using conversion from client locale to server locale.
-
8 minutes ago, David Heffernan said:Thanks for the correction. The main point stands, namely that Chr(11200) is perfectly valid.
This is true for strings. However in the example it's used to assign the value to ansistring:
var MyAnsiString: AnsiString;
AnsiString is not a unicode string thus there is no chr(11200) most probably the code page of the ansistring will have no conversation for that unicode code point thus will be converted to ?
-
At least I won this bet. You should always post the parent class as don't everyone will have the complete source. By openning the System.Classes.pas it's clear what to do:
procedure TCustomMemoryStream.SetPointer(Ptr: Pointer; const Size: NativeInt);
change the method signature to match.
-
You should at least provide a compiler error message. From here we don't know which class it's inherited from.
I don't like to gamble but will make an exception my guess is that you should change the parameters of the method to match the signature from the parent class?
-
Delphi 11 can be tough on debugging. I also have problem to debug a code in a package. Sometimes I can place a break point and works as expected sometimes I have to use ShowMessages to debug.
Build all can help (but not always).
-
Without seeing a code the UI reading from a working thread could be a problem as that must be synchronized. The working thread should post information or synchronize with the UI.
-
2 hours ago, XylemFlow said:I wonder why they didn't implement such a basic feature?
Most probably there was no QP ticket to implement this logic?
-
46 minutes ago, isola said:What does the option [Use debug dcus] add to the code?
You can find out in the Help:
Use debug .dcus
The debug DCUs contain debug information and are built with stack frames. When this option is checked, the compiler adds the debug DCU path to the search paths specified in Debug Source Path on the Embarcadero Debuggers page.
-
10 minutes ago, Al T said:I'm still looking for a AUTOMATIC solution... not something you have to do extra things to solve
Open a ticket at https://quality.embarcadero.com/ with the steps how to get Access Violation.
-
Yes you can, before you compile the package uninstall all the packages that depends on that one. That should improve the situation.
Unfortunately this is a "known" issue and impossible to report (as it's hard to make the required test case).
PS. For a project group I even have a situation that some days Access Violation is almost every time triggered when I compile an application without runtime packages.
-
uses Xml.XMLIntf, Xml.XMLDoc; procedure TForm1.Button1Click(Sender: TObject); var MyXMLDocument : IXMLDocument; FounderNode : IXMLNode; begin MyXMLDocument := TXMLDocument.Create(nil); MyXMLDocument.Active := true; MyXMLDocument.Version:='1.0'; MyXMLDocument.DocumentElement := MyXMLDocument.CreateNode('ab', ntElement,''); MyXMLDocument.DocumentElement.DeclareNamespace('xsi', 'https://www.guru99.com/XMLSchema-instance'); MyXMLDocument.DocumentElement.DeclareNamespace('xsd', 'https://www.guru99.com/XMLSchema'); MyXMLDocument.DocumentElement.SetAttributeNS('xmlns', '','MyString'); FounderNode := MyXMLDocument.DocumentElement.AddChild('founder'); FounderNode.NodeValue:='Krishna'; MyXMLDocument.SaveToFile('TestOne01.XML'); MyXMLDocument.Active := false; end;
You have to set the version and MyString should be the 3rd parameter not the second one.
-
1
-
-
There is a hope for Delphi 11 CE; my bet is that it's going to be released after Delphi 12. In order to learn more about the release date and roadmap I suggest to apply for a job at Embarcadero (that's the only legal way to get information).
Naming FireDac Connection Weird
in Databases
Posted
you have a local variable fdc.
Try self.fdc.Connected:= True;