delphi-10.2-tokyo

How can we connect with a website? Getting SSL error 1409442E

♀尐吖头ヾ 提交于 2020-03-16 06:22:17
问题 I am using Delphi 10.2 Tokyo, trying to download some information from a web server. I pass the command URL https://poloniex.com/public?command=returnCurrencies through this function using Indy 10.6.2.5366 (the command works if I paste it in a browser): function ReadHTTPS(const url: string): string; var IdHTTP: TIdHTTP; IdSSL: TIdSSLIOHandlerSocketOpenSSL; begin IdHTTP := TIdHTTP.Create; try IdSSL := TIdSSLIOHandlerSocketOpenSSL.Create(IdHTTP); IdHTTP.IOHandler := IdSSL; result := IdHTTP.Get

How can we connect with a website? Getting SSL error 1409442E

两盒软妹~` 提交于 2020-03-16 06:22:01
问题 I am using Delphi 10.2 Tokyo, trying to download some information from a web server. I pass the command URL https://poloniex.com/public?command=returnCurrencies through this function using Indy 10.6.2.5366 (the command works if I paste it in a browser): function ReadHTTPS(const url: string): string; var IdHTTP: TIdHTTP; IdSSL: TIdSSLIOHandlerSocketOpenSSL; begin IdHTTP := TIdHTTP.Create; try IdSSL := TIdSSLIOHandlerSocketOpenSSL.Create(IdHTTP); IdHTTP.IOHandler := IdSSL; result := IdHTTP.Get

Trying to compile iOS device 64-bit in Delphi

狂风中的少年 提交于 2020-01-25 08:27:04
问题 I'm using Delphi 10.2 Update 3, with an iOS target of 11.3 and an iPad running iOS 10.3.3. When I try to compile my project for a iOS device, this error occurs: [DCC Error] E2597 ld: warning: directory not found for option '-FC:\Users\gustavo.reinert\Documents\Embarcadero\Studio\SDKs\iPhoneOS11.3.sdk\System\Library\PrivateFrameworks' ld: warning: directory not found for option '-LC:\Users\Marcio.Amorim\Documents\Embarcadero\Studio\SDKs\MacOSX10.13.sdk\usr\lib\system' ld: file not found: /usr

How do I get the version number of the current project using ToolsAPI in Delphi 10.2

北城余情 提交于 2020-01-23 07:34:39
问题 In Delphi 2007 I can easily get the version information of the current project using the following ToolsAPI calls: procedure Test; var ProjectOptions: IOTAProjectOptions; Project: IOTAProject; Major: Variant; Minor: Variant; Release: Variant; Build: Variant; begin // GxOtaGetCurrentProject is a function in GExpert's GX_OTAUtils unit that returns the current IOTAProject Project := GxOtaGetCurrentProject; if Assigned(Project) then begin ProjectOptions := Project.ProjectOptions; if Assigned

Delphi - Using TEdit.tagObject to point to another object

落爺英雄遲暮 提交于 2020-01-16 16:07:46
问题 I am using a descendant of TEdit and using TagObject to store an object. I'm using Firemonkey. In short, I am working with another object and want to assign a property of that object to my TMyEdit, so that whenever I load the object, the text gets updated, and when I change the text, the object gets updated. So I do it like this: Edit1 : TMyEdit; MyElement:TMyProperty; ... Edit1.TagObject:=TMyTextProperty(MyElement); (The typecast is necessary for other reasons. I mention it just in case it

Datasnap in 10.3 Rio incompatible with previous versions

那年仲夏 提交于 2020-01-15 05:48:05
问题 We have a problem with Datasnap RESTfull, it seem to have an incompatibility between 10.3 Rio and 10.2 Tokyo (and all bellow) about Datasnap RESTfull function implementation. The problem: We have a server, builded with 10.2 currently running and servicing a lot of users. If we update the server with the one compiled with Delphi 10.3 Rio, the current 10.2 client (Win, MacOS, iOS, Android) receive the following error message: Internal: Field FValue cannot be found in type TJSONString. Conversly

Delphi - Making asynchronous calls to WinRT API using TTask.Future

丶灬走出姿态 提交于 2020-01-14 04:23:10
问题 Related to this question, I am trying to implement a procedure that uses the WinRT API to set the desktop wallpaper. To mimic the await functionality in C#, I am using TTask.Future (link) as outlined here and here. My implementation looks like this: class procedure TUtilityWin.SetWallpaper(AFileName: String); var lStorageFile: IStorageFile; liao_storagefile: IAsyncOperation_1__IStorageFile; lFutureTask: IFuture<IAsyncOperation_1__IStorageFile>; begin //WinRT Implementation if TUserProfile

Why the exception is not caught by the try… except end;?

狂风中的少年 提交于 2020-01-12 12:50:30
问题 I have this code (that runs under iOS with Delphi Tokyo): procedure TMainForm.Button1Click(Sender: TObject); var aData: NSData; begin try try aData := nil; finally // this line triggers an exception aData.release; end; except on E: Exception do begin exit; end; end; end; Normally the exception should be caught in the except end block, but in this case it is not caught by the handler and it is propagated to the Application.OnException handler. Access violation at address 0000000100EE9A8C,

Why the exception is not caught by the try… except end;?

社会主义新天地 提交于 2020-01-12 12:50:11
问题 I have this code (that runs under iOS with Delphi Tokyo): procedure TMainForm.Button1Click(Sender: TObject); var aData: NSData; begin try try aData := nil; finally // this line triggers an exception aData.release; end; except on E: Exception do begin exit; end; end; end; Normally the exception should be caught in the except end block, but in this case it is not caught by the handler and it is propagated to the Application.OnException handler. Access violation at address 0000000100EE9A8C,

TmemoryStream Server Out Of Memory On receiving stream

百般思念 提交于 2020-01-11 07:26:10
问题 All I'm trying to do is send a stream with TSockets, but I'm having an "out of memory" error. I managed to send files, just not images. In the server Form's OnCreate event, I'm creating the stream. For the client, in the Form's OnCreate I'm creating the stream, also a bmp. I've tried to see if it's not sending, but it's sending something, only I can't tell what. On the server side, I've tested sending commands to the client, and I know they send, also I've tested with booleans, but still get