Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Load File from android and ios app
Forum Updated to NodeBB v4.3 + New Features

Load File from android and ios app

Scheduled Pinned Locked Moved Mobile and Embedded
4 Posts 5 Posters 1.4k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    mkdh
    wrote on last edited by
    #1

    I use Qt Widgets on Qt 5.4.0 for Android and iOS (Mac).

    I has a file in my mac.

    How do I get the file on my Android and iOS simulator?

    I code widget for desktop before.

    I open the file using QFileDialog::getOpenFileName().

    But it seems not suit for the Android and iphone simulator.

    1 Reply Last reply
    0
    • H Offline
      H Offline
      Huragan
      wrote on last edited by
      #2

      I have the same problem. My solution is do your own function which will show you list of files in folder selected by you. You have to do your own UI for this function which also will fit to display resolution. It will be some fun. :)

      Greeting from Poland, land of best software engineer, I think so. :)

      Śmieje się, bo życie jest śmiechu warte. - Petroniusz "Quo Vadis"

      1 Reply Last reply
      0
      • L Offline
        L Offline
        lambda
        wrote on last edited by
        #3

        Try to build with Ministro, but I'm not sure if it has been implemented with Qt 5.4 to get the native Android UI.

        1 Reply Last reply
        0
        • P Offline
          P Offline
          PSI-lbc
          wrote on last edited by
          #4

          If the file is on the Mac, you can include the file as a project resource and load with QFile

          @QFile inputfile( ":/data/yourfile.xml" );@

          Then write to the data directory on the android or ios device.

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved