Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-24485

create: "property variant img: {'0'} not accepted

    XMLWordPrintable

Details

    • Bug
    • Resolution: Invalid
    • Not Evaluated
    • None
    • Qt Creator 4.12.4
    • Quick / QML Support
    • None

    Description

      I tried to create an item that could be used to hold an array of elements
      (strings), dynamically generated. They are to be stored as a property of
      a "glossary" object (a Qml Item). I created a separate file called "Img_glossary.qml"
      in the same directory as the project.

      In the project qml file I invoked the "Img_glossary" object specifying a size
      of 10, and prefix and suffix ( custom property values) when I run the debugger
      I receive a message:

      file:​/​/​/​home/​leemke/​proj/​qt/​Img_​glossary/​Img_​glossary.​qml:​7:​4:​ Unable to assign QJSValue to QString

      Yet when I review documentation, I seem to be following the example.
      I have included 3 snapshots. Two of them show the 2 qml files, and
      the fourth is a snapshot of the documentation.

      What is wrong? (documentation or something I did)?

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            ulherman Ulf Hermann
            lawrence.emke Lawrence Emke
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes