Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Executing external C programme in QT
QtWS25 Last Chance

Executing external C programme in QT

Scheduled Pinned Locked Moved Unsolved General and Desktop
3 Posts 3 Posters 261 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.
  • Q Offline
    Q Offline
    qtwithanzo
    wrote on last edited by qtwithanzo
    #1

    Hello,
    I am creating a simple widget application with a button. my intent is to execute a c code which is in separate file (simple.c) on the button click . Kindly help.

    jsulmJ JonBJ 2 Replies Last reply
    0
    • Q qtwithanzo

      Hello,
      I am creating a simple widget application with a button. my intent is to execute a c code which is in separate file (simple.c) on the button click . Kindly help.

      jsulmJ Offline
      jsulmJ Offline
      jsulm
      Lifetime Qt Champion
      wrote on last edited by
      #2

      @qtwithanzo said in Executing external C programme in QT:

      Not sure if this is doable or not

      It is. See https://doc.qt.io/qt-5/qprocess.html

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      4
      • Q qtwithanzo

        Hello,
        I am creating a simple widget application with a button. my intent is to execute a c code which is in separate file (simple.c) on the button click . Kindly help.

        JonBJ Offline
        JonBJ Offline
        JonB
        wrote on last edited by JonB
        #3

        @qtwithanzo
        Like @jsulm says if you mean you compile that simple.c into some runnable external program.

        But if by "separate file (simple.c)" you simply mean the code you want executed happens to be in a separate C file, but nothing to do with a separate program/executable, then you need to integrate simple.c into your Qt source project.

        1 Reply Last reply
        3

        • Login

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