-
Content Count
1406 -
Joined
-
Last visited
-
Days Won
22
Everything posted by programmerdelphi2k
-
Any Demo On How To Use TBiometricAuth In Delphi
programmerdelphi2k replied to stacker_liew's topic in FMX
DAMMMMMHHHH ðĪŠ -
Any Demo On How To Use TBiometricAuth In Delphi
programmerdelphi2k replied to stacker_liew's topic in FMX
better read more about it https://developer.android.com/training/sign-in/biometric-auth -
Any Demo On How To Use TBiometricAuth In Delphi
programmerdelphi2k replied to stacker_liew's topic in FMX
@stacker_liew I just to say: it works for me in Android 11 / RAD 11.3 FMX 64bits project! FMX_BioMetric_usage.7z -
@karlxnaizu at first, always show your "code" to analise, ok? maybe, your problem can be a "object not created yet", or be, you are trying show a form or any other object that was not created like this: then, It should be: now, look at your "Form created" on event OnClick, for example, or any other event used to see any problem... NOTE: use a "BreakPoint" on the line that you need "stop" and see whats happens... F5 = breakpoint, F8 = continue next line on debug, F9 = continue running in debug... etc...
-
@JusJJ I think that easy way would be: right-click on StringGrid and "Edit Custom Style..." option -> to create a StyleBook customized into it, you need just access 2 properties: StyleGrid1Style1 --> and change: "background -> Visible=false" and "linefill -> Brush.Kind = none" in StringGrid options, uncheck "Show Header"
-
my first choice would be: excluding any "complex called" on form starting... like: while TRUE resulted, using threads, etc..
-
Delphi 10.4.2 add support for Android 13
programmerdelphi2k replied to hackbrew's topic in Cross-platform
@hackbrew I would try the following: first, update the Android SDK/NDK files for correct use in Delphi; you can find here on the forum a post of mine on how to manually update the Android SDK/NDK, instead of using Android Studio, as there is a small incompatibility of the configuration files generated by it, and, the manual update of Android ( SKDManager.bat) from the command line! However, if you don't mind some "Warnings", you can use any of the SDK/NDK update ways (I use the manual update) after that, you can use JAVA JDK or AdoptOpenJDK, as specified by Embarcado: then follow the Embarcadero requirement (I use AdoptOpenJDK by default) now, in Delphi, always prefer to delete the old settings and recreate them so that there is no question about the paths! NOTE: Please note that Delphi does not use the latest releases, but rather points to a certain version, so anything outside of that is up to you! https://en.delphipraxis.net/topic/7949-problem-on-update-sdk-ndk-in-delphi-11/?tab=comments#comment-66699 -
Any Demo On How To Use TBiometricAuth In Delphi
programmerdelphi2k replied to stacker_liew's topic in FMX
@stacker_liew you need this to "work": tested in Android 11 (API 30)... (using default targetSdkVersion = 32 by Delphi) PermissionBiometric: TArray<string>; //... OnCreate Form: -------------- PermissionBiometric := ['android.permission.USE_BIOMETRIC']; // , 'android.permission.USE_FINGERPRINT']; // NOT mandatory == FIXED! BiometricAuth1.PromptDescription := 'my description'; // mandatory BiometricAuth1.PromptTitle := 'my title'; // mandatory BiometricAuth1.BiometricStrengths := [ TBiometricStrength.DeviceCredential { , others... }]; // mandatory //... procedure TForm1.BiometricPermissionRequestResult(Sender: TObject; const APermissions: TClassicStringDynArray; const AGrantResults: TClassicPermissionStatusDynArray); begin // 2 permissions involved: USE_BIOMETRIC + USE_FINGERPRINT if (Length(AGrantResults) = 1 {2}) and (AGrantResults[0] = TPermissionStatus.Granted) then // and (AGrantResults[1] = TPermissionStatus.Granted) then BiometricAuth1.Authenticate; //... end; //... procedure TForm1.Button1Click(Sender: TObject); begin PermissionsService.RequestPermissions( { } PermissionBiometric, { } BiometricPermissionRequestResult, { } DisplayRationale); end; // ... procedure TForm1.BiometricAuth1AuthenticateFail(Sender: TObject; const FailReason: TBiometricFailReason; const ResultMessage: string); begin TDialogService.ShowMessage('Failed!'); end; procedure TForm1.BiometricAuth1AuthenticateSuccess(Sender: TObject); begin TDialogService.ShowMessage('Successed!'); end; -
if solved, then, it's solved!
-
I think that it's not necessary create a new table, at all! just create a new field (varchr(50)) copy the records using "UDPATE" command (like above etc...), it's ready!, now you can do it a little script and use FDScript to execute it! (create field, update field, delete field) Of course, you need update your "EDITs" on forms/datasource as said above!
-
I use SQLite Expert Pro and it's possible just "resize" the field, later, update your FDQuery to new size, as above! BUT, the field (names) contains "more char than" new resize... then need update the values too! for that FireDAC dont accept this "way"
-
@Jeff Steinkamp try this: I would do the following test: make a copy of the DB and change the definitions of the 3 tables! Using an appropriate tool, you have one, I would reset the field size to a larger value, for example if you already have 50 characters then let's time make the field size 100! NOTE: when increasing the field size, normally no data should be lost, which would happen the other way around! now in FireDAC, if the fields are defined dynamically, in your forms and datamodules, then just do: right-click on the table component, and access the "Fields Editor", delete all the fields there, and, add them all again! done, that would be it! now do the necessary tests to visualize the data, normally, running the recompiled program. if everything is ok, now you can easily test the program in production, and you can create a "script" (FDScript - FireDAC can be a support application to analyze and change the DB of other users. Or, you create this function within your own application, however, I think a separate little application would be better, just for this evaluation function. if it is not possible to change the column size, you could create a new column with the desired size (greater than the previous one), copy all records to the new column, delete the old column, and rename the new column with the name of old. (if it is not a dependency on a "Foreign Key", for example. In this case you will need some other actions first!) <-- that way, it's more simple: now, just update your "FDQuery fields using "Fields Editor -> delete old field, add new field", in my example: field is "NAMES"
-
Why Should a C-Sharper Learn Delphi?
programmerdelphi2k replied to Qasim Shahzad's topic in General Help
maybe a typo- 14 replies
-
other way, hard-coded can this way - no more Project->Options it's necessary: create a file any name with .RC extension and add it your project now, just BUILD your project! NOTE: you can create a "RC" to share with all project, and a "RC" specific to one project using vars in shared-RC, just "include it" -> #include "sharedversiondefs.rc" // // RC file script // #define VER_MAJ 1 #define VER_MIN 2 #define VER_SUB 3 #define VER_BUILD 4000 // #define VER_P_MAJ 5 #define VER_P_MIN 6 #define VER_P_SUB 7 #define VER_P_BUILD 8000 // VS_VERSION_INFO VERSIONINFO // FILEVERSION VER_MAJ,VER_MIN,VER_SUB,VER_BUILD /* 1,2,3,4000 */ // PRODUCTVERSION VER_P_MAJ,VER_P_MIN,VER_P_SUB,VER_P_BUILD /* 5,6,7,800 */ // // string terminated with null #define MyNameInternal "HelloWorld\0" #define MyNameProduct "Hello Product Name\0" // #define MyCompanySTR "My Company Name Delphi\0" #define MyDescriptionSTR "This my specific file description to "MyCompanySTR"\0" #define MyFileVersionSTR "FILEVERSION\0" #define MyInternalNameSTR "This is my specific internal name "MyNameInternal"\0" #define MyLegalCopyrightSTR "(c) 2022 "MyCompanySTR"\0" #define MyProductNameSTR "This is my product name: "MyNameProduct"\0" #define MyProductVersionSTR "9.8.7.6\0" // unfortunatelly, it dont accept the same way than "MyFileVersionSTR" above // BEGIN BLOCK "StringFileInfo" BEGIN BLOCK "040904E4" /* your language code */ BEGIN VALUE "CompanyName", MyCompanySTR VALUE "FileDescription", MyDescriptionSTR // VALUE "FileVersion", MyFileVersionSTR // using FILEVERSION above! else, use this! VALUE "InternalName", MyInternalNameSTR VALUE "LegalCopyright", MyLegalCopyrightSTR VALUE "ProductName", MyProductNameSTR VALUE "ProductVersion", MyProductVersionSTR END END BLOCK "VarFileInfo" BEGIN VALUE "Translation", 0x409, 1252 /* lang, codepage */ END END
-
try this: the version number will be changed (automatically or not) when you "BUILD" the project, (or manually), then... Project->Options-> use RELEASE option do the changes necessary, like define your start values on "Module version number" use "Auto increment build number" -- dont worry about anymore! now, "BUILD" your project and see the changes! anyhing, try "delete" the "xxxxxx.DPROJ" if any inconsistence -> remeber that your old setup will be losted, of course!
-
Why Should a C-Sharper Learn Delphi?
programmerdelphi2k replied to Qasim Shahzad's topic in General Help
@Qasim Shahzad and more... Build Native Apps 5x Faster With One Codebase ( Delphi1 running under Delphi11.3 compilation, yeah! it's possible, respecting the "changes over years") For Windows, Android, iOS, macOS, and Linux + Internet of Things (IoT) https://www.embarcadero.com/products/delphi/features/internet-of-things-iot DONT FOGET: and the "BUGs...." ð but, where it does not exists, isnt?- 14 replies
-
Why Should a C-Sharper Learn Delphi?
programmerdelphi2k replied to Qasim Shahzad's topic in General Help
@Qasim Shahzad As the popular saying goes: Knowledge does not occupy space! (unlike knowledge books ð That said, there's not much to argue about knowing something more and enriching your knowledge! What other arguments will be just rhetorical, and, in the end, will not make much sense to anyone who wants to gain knowledge! (like you). Okay, maybe it's not as commercial or popular in the environment you work in. Bear in mind that the "market" will always dictate the rules! But what about your personal fulfillment? If it is not suitable in your business environment, it may be to your personal satisfaction. And thus make your day-to-day more productive, even if you use another programming language at work!- 14 replies
-
set of object instances
programmerdelphi2k replied to dummzeuch's topic in RTL and Delphi Object Pascal
a little test using TList + TEdits LMyEdits.LEAddEdit(LEdit); VCL_TList_TEdit_class.7z -
Delphi Professional Database Connectivity
programmerdelphi2k replied to hackbrew's topic in Databases
I've been able to get "FireDAC" in a 10.3 or 10.4 (I don't remember exactly as it was a few years ago), but it required copying a lot of files from RAD Arch! don't ask me which ones? Of course, this was just a test for myseft, after all I was using RAD Arch! but it worked... then I deleted everything! -
ok, for sure! but how many "process" can be in a system in a moment? ... 100, 1000, 10000... how many fragmentations we can have on 32GB memory, when using Chrome ? ð dont forget "GetApplicationInstances" always return an "array"... same using a TList (with internal array usage) into it!
-
Now imagine the following: I, develop an application using an Embarcadero CE edition! I'm on my latest generation notebook, with an nVida 40xx video card, running my favorite online game, connected to a Microsoft public wifi (if any)... I'm there, killing all the opponents.... however, I forgot that on my notebook is my application created in an Embarcadero CE edition is running, because I was registering my favorite songs... and, suddenly, the Embarcadero servers are about to send a warning letter to Microsoft, because I I'm using their wifi network... what happens now? I don't have a VPN (and if I do, they can find me)... Does Microsoft get the letter or do I?
-
for sure, but in sometime it do it! capacity > n = reallocate it please! at end, a List will do it, expand the items like a array! or a array-of-pointers!
-
look, I think that this explains more than words type TMyRec = record Id: integer; // can generate random values, yes! but does matter in function below! Name: string; end; function FuncReturnArray(AddRecordOnArray: boolean): TArray<TMyRec>; // none random value is returned var LRecX: TMyRec; begin // the "result" will be "default" = [], does matter if you the content can have random values, when call this function! // There is not content! so, none "record" can be accessed // result := []; // if you want do it! // ... if AddRecordOnArray then begin LRecX.Id := 1; LRecX.Name := 'hello1'; result := result + [LRecX]; end; end; procedure TForm1.Button1Click(Sender: TObject); var LReturn : TArray<TMyRec>; LRecTest: TMyRec; begin LRecTest.Id := 123; LRecTest.Name := 'hello world'; // // FuncReturnArray(true) := LRecTest; // it's not possible! // LReturn := FuncReturnArray(false {true}); // for var R in LReturn do ShowMessage(R.Id.ToString + ', ' + R.Name); // ShowMessage(length(LReturn).ToString); // // if dont exists any record on array, for sure you'll a exception, not? if length(LReturn) > 0 then ShowMessage(LReturn[0].Id.ToString + ', ' + LReturn[0].Name); end;
-
I think that Embarcadero's proposal is very flawed and misleading, due to the fact that it defines the tool as "intended for beginners, students, and not commercial use, or with a maximum revenue of $5000/year". Let's see, the colleague above said that when connecting to the wifi network of the company he works for, he was caught and unequivocally accused of using the application developed with the CE edition, commercially, because the company where he works, is known and, supposedly, has an income greater than $5000/year. Ok, so, here we have a clear privacy violation, the Embarcado tool, developed the application and, inadvertently, "embedded" a code outside the application, which, in a surreptitious way, sends data to its servers, however, only the data of use, but also personal information enabling the collection of private information, such as the IP identification, as well as the possible wifi network in use, which among many other information that goes beyond the minimum necessary to diagnose information about the software, can identify which company (in this case) is using an application that was developed by the CE edition. I think it would be much clearer to explicitly ask the would-be user of your tool to complete a registration, with personal data, explicitly informing the purpose of use, and thus informing them of their respective responsibilities in court. Anyway, Embarcadero sells an idea that in practice brings more misfortunes than benefits. She could simply put a "clear and explicit code of "NON-COMMERCIALIZABLE DEMO AND FOR A DETERMINED TIME OF USE" when the application was executed, making it very clear that the generated software will be only, and only, for the use of the developer. And, in the case of NGOs, there would be another type of exclusive use license for this purpose. Complicated, but necessary so that there are no margins for another understanding! As always, cheap is expensive! And, we must look into the teeth even of the horses given to us!
-
Definitely not! because the expected target (function return) is an "Array", so if the array is empty, there is nothing to expect from its "possible" content (the records), and if there is "content", there will be "records" with values!