Click here to Skip to main content
15,891,136 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I need to execute my QT program from Window command line interface. What changes i need to do in Main() and how i can call this through command line??
My program main function is..
C++
int main(int argc, char *argv[])
{
    QApplication a(argc, argv);
    MainWindow w;
    w.show();

    return a.exec();
}


Any suggestion and help would be appreciated.
Thanks
Posted
Comments
Sergey Alexandrovich Kryukov 14-Jan-16 11:09am    
It depends on what you want to achieve, what is your command line and what is expected in command line.
—SA
Richard MacCutchan 14-Jan-16 11:17am    
Why don't you just try it to see what happens?

1 solution

You can start any Windows program from a command prompt. Just enter the complete path at the prompt and press the Return key. There must nothing be changed in the source code.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900