Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Developing U++ » U++ Developers corner » How does one get argc and argv parms when making use of GUI_APP_MAIN?
How does one get argc and argv parms when making use of GUI_APP_MAIN? [message #56785] Fri, 16 April 2021 04:52 Go to previous message
ptkacz is currently offline  ptkacz
Messages: 89
Registered: March 2017
Member
> How does one get argc and argv parms when making use of GUI_APP_MAIN?

Ok, I did some digging and there appears to be a CommandLine() function that returns a Vector<String>&. When I run the program from command line, the following returns a value of ZERO:

const Vector<String>& argc = CommandLine();

cout << "argc = " << to_string(argc.GetCount()) << endl;


In a C or C++ program with main(int argc, char **argv) provided, and the program is launched with no arguments, argc returns a value of 1, so why does the count for the String Vector for CommandLine() come back as ZERO?


Peter

[Updated on: Fri, 16 April 2021 05:21]

Report message to a moderator

 
Read Message
Read Message
Read Message
Previous Topic: UppHub - new package registration
Next Topic: [Proposal] Markdown to QTF converter/parser
Goto Forum:
  


Current Time: Sun Apr 28 15:04:42 CEST 2024

Total time taken to generate the page: 0.03187 seconds