Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation on 05/22/25 in all areas

  1. Uwe Raabe

    Problem with Calculated fields in a TFDQuerry

    Calculating fields is done on each record at several occasions. Any change to the current record, be it by navigating or switch to and from edit mode. AfterOpen is dataset based and when it is called, at least the first record is already loaded and all fields contain their values, including the calculated ones.
  2. Uwe Raabe

    Problem with Calculated fields in a TFDQuerry

    I would use a caching approach. In OnCalcFields try finding the ID in the dictionary like you already do. If not found, get the file size as you currently do in OnAfterOpen and add it to the dictionary.
  3. Anna Blanca

    Why i haven't Android SDK after intall RAD Studio 12?

    I tryed Platform Features, like in your message and installed Android SDK/NDK - error solved. But starts another bug: my app watever not compile in this time with message from my new screens:
  4. KimHJ

    RIO or Server 2016 R2 Problem

    They response that this is a self manage VPS and I could request from some of their partners. I went online and create a new VPS with Windows Server 2025 and everything works fine on that server.
  5. Perhaps you fix your links,# or, Spam, spam, spam, ...
  6. Anders Melander

    Project Release Icon not Showing

    SHChangeNotify got me thinking... Assuming a call to SHChangeNotify(SHCNE_ASSOCCHANGED) is all that is needed to rebuild the cache, is there something in Windows that we know makes that call? A quick search of "the source" gave the answer: The assoc command of the Windows shell; All it does is write an entry to the registry and then make the SHChangeNotify call. assoc .foobar=text Voila! If you want to remove the file association entry again then it's just: assoc .foobar= Admin privs required, btw.
  7. DelphiUdIT

    Indy, TauruTLS and TLS 1.3

    Delphi version 12.3 with patch. I used the TaurusTLS from https://github.com/JPeterMugaas/TaurusTLS with bundle version of Embarcadero to activate the use of TLSv1.3. Inside a web server project that I use for testing, I substitute the old PR299 (openSSL 1.x and 3.x wrapper) with TaurusTLS and all is perfect working with really less change. I don't use the component at design time, so with some $IFDEF I adapt the code that can work with old PR299 (TLSv1.3), only a bundle distro (TLSv1.2) and the new TaurusTLS (TLSv1.3 with all the new OpenSSL 3.x DLLs) with only a recompile action. I have more server place with some certificates from Let's encrypt and redirection function (http port 80 -> https port 443) and is all good. Thanks to @Remy Lebeau and @J. Peter Mugaas
  8. I have hacked together some code that may help here. Create a new VCL Forms Application, drop a button and a memo onto the form and use the following code: const cArr: TArray<string> = [ // 'object RESTClient1: TRESTClient', // ' BaseURL = ', // ' ''https://api-eu1.XXXXXXXXXXXXXXX/ORD''', // ' Params = <>', // 'end', // 'object RESTRequest1: TRESTRequest', // ' AssignedValues = [rvConnectTimeout, rvReadTimeout]', // ' Client = RESTClient1', // ' Method = rmPOST', // ' Params = <', // ' item', // ' Kind = pkHTTPHEADER', // ' Name = ''x-api-compleat-key''', // ' Value = ''0aXXXXXXXXXXXXXXXXXXXXXX94''', // ' end', // ' item', // ' Kind = pkREQUESTBODY', // ' Name = ''body9BE6CF603159471FB026D7FF6FC3D2DB''', // ' Value = ', // ' ''{"master_id":1,"LayoutID":"d967cc4c-5b2b-4474-8cac-a71f9684ee70"'' +', // ' '',"TransactionStatus":"SAV","Reference":1,"PoNumber":"ORD1","Date'' +', // ' ''Created":"2008-07-08","SupplierName":"TMB","CurrencyCode":"GBP",'' +', // ' ''"SupplierID":"1234","LineItems":[{"master_id":1,"Description":"G'' +', // ' ''obo Original","UnitCost":"100.00","Net":"100.00","Quantity":1,"T'' +', // ' ''ax":0,"Gross":100},{"master_id":1,"Description":"Gobo Copy","Uni'' +', // ' ''tCost":"50.00","Net":"100.00","Quantity":2,"Tax":0,"Gross":100}]'' +', // ' ''}''', // ' ContentType = ctAPPLICATION_JSON', // ' end>', // ' Response = RESTResponse1', // 'end', // 'object RESTResponse1: TRESTResponse', // 'end', // '']; procedure TForm649.Button1Click(Sender: TObject); var binary: TMemoryStream; cmp: TComponent; lst: TStringList; stream: TMemoryStream; begin RegisterClasses([TRESTClient, TRESTRequest, TRESTResponse]); lst := TStringList.Create; try lst.Add('object myName: TComponent'); // name doesn't really matter lst.AddStrings(cArr); lst.Add('end'); stream := TMemoryStream.Create; try lst.SaveToStream(stream); stream.Position := 0; binary := TMemoryStream.Create; try ObjectTextToBinary(stream, binary); binary.Position := 0; binary.ReadComponent(Self); // Self puts the code into the form itself, but any other component will do finally binary.Free; end; finally stream.Free; end; finally lst.Free; end; cmp := FindComponent('RESTRequest1'); if cmp is TRESTRequest then begin Memo1.Lines.Add(TRESTRequest(cmp).Params[1].Value); end; end;
×