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. [Solved] Redirecting log messages
QtWS25 Last Chance

[Solved] Redirecting log messages

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

    Hello,

    Is there any way to catch all console.log() messages through QML. By default all logged messages are printed on terminal. What if I want to log these messages to a file. (not by using UNIX redirection operators, consider a scenario where I'm running my app on cellphone.)

    1 Reply Last reply
    0
    • A Offline
      A Offline
      andre
      wrote on last edited by
      #2

      Just use the standard Qt way to re-direct log messages (qInstallMsgHandler, look it up in the docs).

      1 Reply Last reply
      1

      • Login

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