Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Could not load qml file on Deployment on Android Device
Forum Updated to NodeBB v4.3 + New Features

Could not load qml file on Deployment on Android Device

Scheduled Pinned Locked Moved QML and Qt Quick
2 Posts 2 Posters 1.1k 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.
  • R Offline
    R Offline
    Rambo
    wrote on last edited by
    #1

    I have issue related to loading 1-2 qml files at the time of deployment. I have a code that runs well on emulator but does not load few qml file at the time of delpoyment. For example

    this is my model and on itemClick want to load new qml

    @ListModel {    
     ListElement { name: "Help"; section: "Other";         path:      "settingsHelp.qml"; }
    }@
    

    in Delegate I am loading this qml file like this

    @ help_stack.push(Qt.createComponent(Qt.resolvedUrl(path), help_stack));@

    Just for info, this seetingsHelp.qml exists in same folder

    This code working perfectly on emulator and I have all the deployment setting in place in .pro file such as DEPLOYMENTFOLDERS and qtcAddDeployment. In Addition, I have different qml pages too which are working fine on Deployment so it means deployment setting are fine too I guess.

    Regarding error there is no specific error on logs except one on screen

    @Error: Could not load: file://data/data/com.test.example/files/assets:/qml/help/settingsHelp.qml:-1 File not found@
    

    Any idea what could be problem

    1 Reply Last reply
    0
    • J Offline
      J Offline
      juanmahv
      wrote on last edited by
      #2

      You can try adding the import path explicitely with QQmlEngine::addImportPath(assets:/...).
      Just to be sure.

      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