Swapna [swapna0282@yahoo.co.in] wrote: Can we have more than one value added to positional_options_description ie positional_options_description posOpt; posOpt.add( "A", -1 ); posOpt.add( "B", -1 ); posOpt.add( "C", -1 );
from http://www.boost.org/doc/html/program_options/overview.html#id1591885 http://www.boost.org/doc/html/program_options/overview.html#id1591885 on positional_options_descriptionhttp://www.boost.org/doc/html/boost/program_options/positional_options_descr... - "specifies translation from position to name". So I am not sure if you mean you want to only add more than one value - which the tutorial very well explains; or add more than one value to the same position - which would be absurd. For code like: ============================================= optdesc.add_options() ("input-files-1,i", po::value< vector< string > >(&input_file_1), "Input file name." ) ("input-files-2,i", po::value< vector< string > >(&input_file_2), "Input file name." ) ("input-files-3,i", po::value< vector< string > >(&input_file_3), "Input file name." ) ; po::positional_options_description posopt; posopt.add("input-files-1", -1); posopt.add("input-files-2", -1); posopt.add("input-files-3", -1); all positional values given at command line would be assigned to "input-files-3". ============================================= - Varun Yagain.