delphi-10.2-tokyo

How to use the RecsSkip and RecsMax property of TFDQuery at runtime

為{幸葍}努か 提交于 2019-12-24 07:57:33
问题 I was looking for a skip and take selection in the TFDQuery. The properties I found are .FetchOptions.RecsSkip and .FetchOptions.RecsMax. I use Tokyo 10.2.3 and database Firebird 3 I make the query at runtime and I want to get the start record at 5 and get the 8 next records. I to something like: Result does not skip the fist 5 records var qryTest: TFDQuery; begin qryTest:= TFDQuery.Create(self); qryTest.Connection := self.FDConnection; qryTest.sql.Text:= ' select * from

How to use the RecsSkip and RecsMax property of TFDQuery at runtime

随声附和 提交于 2019-12-24 07:57:01
问题 I was looking for a skip and take selection in the TFDQuery. The properties I found are .FetchOptions.RecsSkip and .FetchOptions.RecsMax. I use Tokyo 10.2.3 and database Firebird 3 I make the query at runtime and I want to get the start record at 5 and get the 8 next records. I to something like: Result does not skip the fist 5 records var qryTest: TFDQuery; begin qryTest:= TFDQuery.Create(self); qryTest.Connection := self.FDConnection; qryTest.sql.Text:= ' select * from

How can I open a url over IPv6 properly?

隐身守侯 提交于 2019-12-24 07:17:35
问题 I have written a function in my iOS and Android apps to open a url. I believe this code will be rejected by iTunes Connect for not connecting over IPv6. This function also raises an error when I build it through Delphi: An access violation occurred at error address 00000001017C4334. (When accessing address 000000000000000) I am using Delphi 10.2.3 Tokyo with Indy 10. How can I fix this error? My code is below: Procedure OpenGoogleForm; Var ipversion : String; Begin // For IPv6 IdTCPClient1

Delphi FireMonkey - Setting Wallpaper on Win 10 does not work when deployed as APPX

回眸只為那壹抹淺笑 提交于 2019-12-22 18:43:13
问题 I have created a simple application using Delphi 10.2 Tokyo (using FireMonkey) that displays images and allows you to set the desktop wallpaper for a selected image. The main code that sets the desktop wallpaper is: class procedure TUtilityWin.SetWallpaper(AFileName: String); begin SystemParametersInfo(SPI_SETDESKWALLPAPER, 0, pChar(AFileName), (SPIF_UPDATEINIFILE OR SPIF_SENDWININICHANGE)); end; While this works great when the application runs on the desktop (as a standalone install), it

Delphi FireMonkey - Setting Wallpaper on Win 10 does not work when deployed as APPX

时间秒杀一切 提交于 2019-12-22 18:43:12
问题 I have created a simple application using Delphi 10.2 Tokyo (using FireMonkey) that displays images and allows you to set the desktop wallpaper for a selected image. The main code that sets the desktop wallpaper is: class procedure TUtilityWin.SetWallpaper(AFileName: String); begin SystemParametersInfo(SPI_SETDESKWALLPAPER, 0, pChar(AFileName), (SPIF_UPDATEINIFILE OR SPIF_SENDWININICHANGE)); end; While this works great when the application runs on the desktop (as a standalone install), it

What has happened to ComboBox.Sorted := True; in Delphi 10.2?

故事扮演 提交于 2019-12-20 06:39:55
问题 Having recently received a 'Tumbleweed' badge for my last question, I am not sure whether I should be asking any more questions, but here goes. I am populating a TComboBox with items from a sqlite table and this works fine. In my previous version of Delphi I was able to use ComboBox1.Sorted := True; to sort the items, but this seems to have disappeared in Delphi 10.2. I can sort the items in the table by applying a query and then populate the TComboBox from the sorted table. However, for

How to use animated gif in Firemonkey?

邮差的信 提交于 2019-12-20 02:35:35
问题 How can I use animated GIF in Firemonky. I can load the gif using Timage but it's not animating. I am using Delphi 10.2 tokyo. 回答1: Use TBitmapListAnimation. Place TImage on Form Place TBitmapListAnimation into TImage like on screenshot: Set properties in TBitmapListAnimation AnimationBitmap - You can use online convertorsm that split gif into frames. http://ezgif.com/split http://www.photojoiner.net/merge-photos/editor/# Set another properties: AnimationCount = 8, AnimationRowCount = 1,

Parameter.AsString failing under Oracle/MSSQL - Parameter.Value 2-byte chars under Oracle

梦想与她 提交于 2019-12-19 16:33:10
问题 After changing to FireDAC I have trouble getting this code to work on MSSQL/Oracle: with DataFormsettings do begin Close; if Params.Count=0 then FetchParams; Params.ParamByName('TT_EMP_ID').Asinteger := AEmpID; Params.ParamByName('TT_FORM').AString := UpperCase(AKey); Open; if (RecordCount>0) then S := FieldByName('TT_VIEWDATA').Asstring; end; AKey and S are both strings. The Open statement gives an error [FireDAC][Phys][MSSQL]-338 Param type changed from [ftString] to [ftWidestring] [FireDAC

Delphi firemonkey - Component that holds a reference to another object - creating an object instance

北慕城南 提交于 2019-12-13 09:39:05
问题 I'm trying to have a TEditDescendant that contains a reference to another object (MyString), so that when I edit the TEdit text, MyString gets updated and vice-versa. This works when MyString is already existing. However, if I need MyEdit to be able to create a MyString, it does not work. The code below is a minimal example: btnCreateMyEdit creates the myEdit and gives it some text. btnCreateMyString creates an instance of myString btnCheck shows the issues: If btnCheck is created AFTER

MSBuild does not work anymore with Tokyo

邮差的信 提交于 2019-12-12 17:04:56
问题 I have multiple project groups that I want to compile at batch. There are over 100 projects in there. In 2010 we had a "make" file like this: call "c:\Borland\RAD Studio\19.0\bin\rsvars.bat" "c:\Program Files (x86)\MSBuild\12.0\Bin\MSBuild.exe" /t:Clean,Build Group1.groupproj Under Tokyo it does not work anymore. I get: C:\Borland\RAD Studio\19.0\Bin\CodeGear.Cpp.Targets(3695,5): error : Error: Unable to open file 'L_ER_FD.RES' [P:\Ent\_common\er\prj\l_er_fd.cbproj] However, the project group