Jump to content

Dave Nottage

Members
  • Content Count

    1609
  • Joined

  • Last visited

  • Days Won

    37

Posts posted by Dave Nottage


  1. 4 minutes ago, KimHJ said:

    I search all forums, but only found Xcode developer with same problem.

    A very quick Google revealed this for me: 

    I suggest checking that you have not accidentally disabled items from the deployment (from the main menu - Project > Deployment)


  2. 46 minutes ago, CoeurdeLeon said:

    I have tried this and cannot see a preview of the file.  What am I doing wrong?

    Set the fdoForcePreviewPaneOn flag on in the Options property. It should be noted however, that this will work only where preview of the selected file type is supported.


  3. 51 minutes ago, bzwirs said:

    Can anybody please help with what I need to do to display the PDF properly.

    I can replicate the behaviour using the original demo, adding a TabControl with 2 tabs. Reversing the calls fixes it for me, i.e. 

      TabControl1.SetActiveTabWithTransition(TabItem17, TTabTransition.Slide, TTabTransitionDirection.Normal);
      FPDFControl.LoadPDF(sFile);

    ..however I can look into why the original way around is not working like it should.


  4.  

    27 minutes ago, David Schwartz said:

    ..it makes up lots of stuff

    Absolutely. Depending on which engines you use, it can recognise this if you "call it out" - why it doesn't realise this from the start is a mystery.

    28 minutes ago, David Schwartz said:

    I'm curious what sorts of things others are successfully using some AI tools for that help with Delphi code?

    I'm having loads of success discovering how to do things that I would otherwise have little or no clue about. Asking the right questions (including follow-up questions), and being able to recognise flaws in the answers, is the key.

    • Like 2

  5. 2 hours ago, JohnLM said:

    I've edited the "AndroidManifest.template.xml" file and changed the value in the %targetSdkVersion% field from 11 to 31

    Most likely you did not edit AndroidManifest.template.xml then, because it does not have a value for targetSdkVersion, it looks like this:

    <uses-sdk android:minSdkVersion="%minSdkVersion%" android:targetSdkVersion="%targetSdkVersion%" />

    More likely you edited AndroidManifest.xml which is generated in the project output folder. AndroidManifest.template.xml is in the root of the project source.


  6. 2 hours ago, JohnLM said:

    I get that above message and then it closes on its own, and the app (this time) does not get installed. 

    The info at that link literally tells you what the problem is, i.e:

    "Reason for this notification: These Play Protect warnings will show only if the app's targetSdkVersion is more than 2 versions lower than the current Android API level. For example, a user with a device running Android 13 (current API = 33) will be warned when installing any APK that targets API level lower than 31. Android Versions and corresponding API levels can be reviewed on the API level page."

     

    You would need to change %targetSdkVersion% in AndroidManifest.template.xml to a value less than 2 versions than the target device, i.e. in your case 29 (Android 10), 30 (Android 11), or 31 (Android 12). Not sure if this will work with XE7 - you might need to upgrade, preferably to Delphi 12.


  7. 3 hours ago, alejandro.sawers said:

    I would like to know if somebody found another way to achieve this.

    You can achieve this by writing code that uses CLLocationManager. Create an instance of it, and examine the value of accuracyAuthorization. If it is CLAccuracyAuthorizationReducedAccuracy and your app needs full accuracy, inform the user to:

    • Go to Settings > Privacy & Security > Location Services.

    • Select your app

    • Toggle the Precise Location switch on

    Example code:

    uses
      iOSapi.CoreLocation;
    
    procedure TForm1.Button1Click(Sender: TObject);
    var
      LManager: CLLocationManager;
    begin
      LManager := TCLLocationManager.Create;
      if LManager.accuracyAuthorization = CLAccuracyAuthorizationReducedAccuracy then
        // Inform the user
    end;

     

    • Thanks 1

  8. 2 hours ago, dlucic said:

    Can someone please help me and point me to where I am going wrong

    Delphi 12.1 (no XE in its title) requires the Eclipse Temurin OpenJDK. You can install it via the Delphi menu - Tools | Manage Features - on the right side, scroll the scrollbox all the way to the bottom, check the checkbox for the OpenJDK and click Apply. Once installed, go to the Java tab of the Android SDK settings and configure keytool.exe and jarsigner.exe options to use the OpenJDK (installs by default under C:\Program Files\Eclipse Adoptium.


  9. 28 minutes ago, Rollo62 said:

    Especially, this is throwing an exception: Just saying, that nothing is required.

    Seems to me that the info is contradictory - the uses-permission is stating that permission to use the camera may be requested (on Android 6 or higher), but the uses-feature entries are stating that the app doesn't require a device with a camera?

    EDIT: Even so, having those entries in the manifest works fine for me.


  10. 15 minutes ago, Rollo62 said:

    So why is INTERNET always there, is this because of "Mobile" app is kindof "Internet", or what?
    Is this a BUG or a FEATURE?

    A bit of speculation on my part, but it's possibly a hangover from when Delphi required gdbserver for debugging. The Internet permission is a bit of a misnomer, since it "Allows applications to open network sockets". This part I know from when debugging was broken in Android 8: There is a private IP network between the IDE and gdbserver

     

    • Thanks 1
×